diff options
author | Bjoern Michaelsen <bjoern.michaelsen@canonical.com> | 2014-12-03 18:56:56 +0100 |
---|---|---|
committer | Bjoern Michaelsen <bjoern.michaelsen@canonical.com> | 2014-12-04 01:10:00 +0100 |
commit | 0794cbf28e2cc5d548853d92b23be85615b2416a (patch) | |
tree | 057ceb3f9498c8db64bdef0440f6ca271797c37a | |
parent | f221da28f676b9f72364394cc52dc49b04cbc17d (diff) |
use C++11 iteration
Change-Id: Ib1c6dd47b9168845ad1b864ffbda01c1d6a3afe8
-rw-r--r-- | sw/source/core/view/viewimp.cxx | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/sw/source/core/view/viewimp.cxx b/sw/source/core/view/viewimp.cxx index 9c9f2860f86b..174e65856b50 100644 --- a/sw/source/core/view/viewimp.cxx +++ b/sw/source/core/view/viewimp.cxx @@ -361,25 +361,22 @@ void SwViewImp::_InvalidateAccessibleParaFlowRelation( const SwTxtFrm* _pFromTxt return; } - SwViewShell* pVSh = GetShell(); - SwViewShell* pTmp = pVSh; - do + for(SwViewShell& rTmp : GetShell()->GetRingContainer()) { - if ( pTmp->Imp()->IsAccessible() ) + if ( rTmp.Imp()->IsAccessible() ) { if ( _pFromTxtFrm ) { - pTmp->Imp()->GetAccessibleMap(). + rTmp.Imp()->GetAccessibleMap(). InvalidateParaFlowRelation( *_pFromTxtFrm, true ); } if ( _pToTxtFrm ) { - pTmp->Imp()->GetAccessibleMap(). + rTmp.Imp()->GetAccessibleMap(). InvalidateParaFlowRelation( *_pToTxtFrm, false ); } } - pTmp = static_cast<SwViewShell *>(pTmp->GetNext()); - } while ( pTmp != pVSh ); + } } /// invalidate text selection for paragraphs |