summaryrefslogtreecommitdiff
path: root/sw/source/core/layout/laycache.cxx
diff options
context:
space:
mode:
authorArkadiy Illarionov <qarkai@gmail.com>2018-11-14 00:57:07 +0300
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-11-14 09:58:55 +0100
commit25622f29b4003307d2ba780ff1232d8b7cdafa35 (patch)
treead15c747685e803deeb5fffd209ae0b5992ac87a /sw/source/core/layout/laycache.cxx
parent638d619866784510dcbf0cadb6eb251208489a73 (diff)
Simplify containers iterations in sw/source/core/[d-l]*
Use range-based loop or replace with STL functions Change-Id: I143e9a769e1c1bb0228933a0a92150f00e3e1f20 Reviewed-on: https://gerrit.libreoffice.org/63347 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sw/source/core/layout/laycache.cxx')
-rw-r--r--sw/source/core/layout/laycache.cxx6
1 files changed, 1 insertions, 5 deletions
diff --git a/sw/source/core/layout/laycache.cxx b/sw/source/core/layout/laycache.cxx
index b507e0933293..2e6ffcc7e315 100644
--- a/sw/source/core/layout/laycache.cxx
+++ b/sw/source/core/layout/laycache.cxx
@@ -1013,14 +1013,11 @@ void SwLayHelper::CheckFlyCache_( SwPageFrame* pPage )
if ( aFlyCacheSet.size() == aFlySet.size() )
{
- std::set< const SwFlyCache*, FlyCacheCompare >::iterator aFlyCacheSetIt =
- aFlyCacheSet.begin();
std::set< const SdrObject*, SdrObjectCompare >::iterator aFlySetIt =
aFlySet.begin();
- while ( aFlyCacheSetIt != aFlyCacheSet.end() )
+ for ( const SwFlyCache* pFlyCache : aFlyCacheSet )
{
- const SwFlyCache* pFlyCache = *aFlyCacheSetIt;
SwFlyFrame* pFly = const_cast<SwVirtFlyDrawObj*>(static_cast<const SwVirtFlyDrawObj*>(*aFlySetIt))->GetFlyFrame();
if ( pFly->getFrameArea().Left() == FAR_AWAY )
@@ -1037,7 +1034,6 @@ void SwLayHelper::CheckFlyCache_( SwPageFrame* pPage )
}
}
- ++aFlyCacheSetIt;
++aFlySetIt;
}
}