diff options
author | Jan Holesovsky <kendy@suse.cz> | 2013-04-17 10:30:28 +0200 |
---|---|---|
committer | Jan Holesovsky <kendy@suse.cz> | 2013-04-17 10:32:42 +0200 |
commit | 09f50c017fe106b7bf94f60933667b55130ea1b5 (patch) | |
tree | 26fffc200825fc86da86d68286c68a8b82ffd798 /sw | |
parent | c3b1ce2097ea3b43234be3dfb1d529335b980ff8 (diff) |
Reintroduce unlockPositionOfObjects().
This unlocking code was accidentally removed in commit
120922361a5928ea4437ffe253ce209abd7060b0. Not sure if it is still necessary,
but I am at the moment unable to prove it is not, so better to be safe :-)
Change-Id: I20a7cf3299de75182f890efb0d192e54c1b2543d
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/core/layout/layact.cxx | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/sw/source/core/layout/layact.cxx b/sw/source/core/layout/layact.cxx index bb469008d05e..71659ce4ab95 100644 --- a/sw/source/core/layout/layact.cxx +++ b/sw/source/core/layout/layact.cxx @@ -498,6 +498,24 @@ SwPageFrm* SwLayAction::CheckFirstVisPage( SwPageFrm *pPage ) return pPage; } +// #114798# - unlock position on start and end of page +// layout process. +static void unlockPositionOfObjects( SwPageFrm *pPageFrm ) +{ + assert( pPageFrm ); + + SwSortedObjs* pObjs = pPageFrm->GetSortedObjs(); + if ( pObjs ) + { + sal_uInt32 i = 0; + for ( ; i < pObjs->Count(); ++i ) + { + SwAnchoredObject* pObj = (*pObjs)[i]; + pObj->UnlockPosition(); + } + } +} + void SwLayAction::InternalAction() { OSL_ENSURE( pRoot->Lower()->IsPageFrm(), ":-( No page below the root."); @@ -597,6 +615,8 @@ void SwLayAction::InternalAction() while ( !IsInterrupt() && !IsNextCycle() && ((IS_FLYS && IS_INVAFLY) || pPage->IsInvalid()) ) { + unlockPositionOfObjects( pPage ); + // #i28701# SwObjectFormatter::FormatObjsAtFrm( *pPage, *pPage, this ); if ( !IS_FLYS ) @@ -655,6 +675,8 @@ void SwLayAction::InternalAction() if( bNoLoop ) pLayoutAccess->GetLayouter()->LoopControl( pPage, LOOP_PAGE ); } + + unlockPositionOfObjects( pPage ); } // A previous page may be invalid again. @@ -769,6 +791,8 @@ void SwLayAction::InternalAction() while ( pPg && ( pPg->Frm().Top() < nBottom || ( IsIdle() && pPg == pPage ) ) ) { + unlockPositionOfObjects( pPg ); + XCHECKPAGE; // #i81146# new loop control @@ -843,6 +867,8 @@ void SwLayAction::InternalAction() } } } + + unlockPositionOfObjects( pPg ); pPg = (SwPageFrm*)pPg->GetNext(); } // reset flag for special interrupt content formatting. |