diff options
author | Bjoern Michaelsen <bjoern.michaelsen@canonical.com> | 2014-12-03 18:55:32 +0100 |
---|---|---|
committer | Bjoern Michaelsen <bjoern.michaelsen@canonical.com> | 2014-12-04 01:10:00 +0100 |
commit | 65a1a6afd3474f2b56f1d42cefeed971411b0d61 (patch) | |
tree | 4e7aa3f949e50276ca1c46d9401f80728b82961e /sw | |
parent | 548a3c8fb5a2a05589159bf4fbde5b37601b728a (diff) |
use C++11 iteration
Change-Id: I06fa257210d58fef53eb8cdce44d5559ad0309f1
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/core/view/viewimp.cxx | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/sw/source/core/view/viewimp.cxx b/sw/source/core/view/viewimp.cxx index 998a1a3fe61a..7355257a977d 100644 --- a/sw/source/core/view/viewimp.cxx +++ b/sw/source/core/view/viewimp.cxx @@ -328,14 +328,11 @@ void SwViewImp::InvalidateAccessibleEditableState( bool bAllShells, { if( bAllShells ) { - SwViewShell *pVSh = GetShell(); - SwViewShell *pTmp = pVSh; - do + for(SwViewShell& rTmp : GetShell()->GetRingContainer()) { - if( pTmp->Imp()->IsAccessible() ) - pTmp->Imp()->GetAccessibleMap().InvalidateStates( ACC_STATE_EDITABLE, pFrm ); - pTmp = static_cast<SwViewShell *>(pTmp->GetNext()); - } while ( pTmp != pVSh ); + if( rTmp.Imp()->IsAccessible() ) + rTmp.Imp()->GetAccessibleMap().InvalidateStates( ACC_STATE_EDITABLE, pFrm ); + } } else if( IsAccessible() ) { |