diff options
author | Noel Grandin <noel@peralex.com> | 2016-05-11 09:53:05 +0200 |
---|---|---|
committer | Noel Grandin <noelgrandin@gmail.com> | 2016-05-12 07:12:21 +0000 |
commit | 875984617cfd6c773eb93f339929eb3fabd3e97b (patch) | |
tree | abb092c1b0d995d55f2f4508801df23377c9cc6d /svx/source/tbxctrls/lboxctrl.cxx | |
parent | 6bc3c2bdc5279314881b7e950d76d4d813470d11 (diff) |
clang-tidy modernize-loop-convert in svx
Change-Id: I09e5243e5dff46ceccef1a707e648ee9cb0c37c5
Reviewed-on: https://gerrit.libreoffice.org/24875
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'svx/source/tbxctrls/lboxctrl.cxx')
-rw-r--r-- | svx/source/tbxctrls/lboxctrl.cxx | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/svx/source/tbxctrls/lboxctrl.cxx b/svx/source/tbxctrls/lboxctrl.cxx index e500aa4d9952..d0e43ab67581 100644 --- a/svx/source/tbxctrls/lboxctrl.cxx +++ b/svx/source/tbxctrls/lboxctrl.cxx @@ -249,8 +249,8 @@ void SvxUndoRedoControl::StateChanged( const SfxStringListItem &rItem = *static_cast<const SfxStringListItem *>(pState); const std::vector<OUString> &aLst = rItem.GetList(); - for( long nI = 0, nEnd = aLst.size(); nI < nEnd; ++nI ) - aUndoRedoList.push_back( aLst[nI] ); + for(const auto & i : aLst) + aUndoRedoList.push_back( i ); } } } @@ -271,8 +271,8 @@ VclPtr<SfxPopupWindow> SvxUndoRedoControl::CreatePopupWindow() ListBox &rListBox = pPopupWin->GetListBox(); rListBox.SetSelectHdl( LINK( this, SvxUndoRedoControl, SelectHdl ) ); - for( size_t n = 0; n < aUndoRedoList.size(); n++ ) - rListBox.InsertEntry( aUndoRedoList[n] ); + for(const OUString & s : aUndoRedoList) + rListBox.InsertEntry( s ); rListBox.SelectEntryPos( 0 ); aActionStr = SVX_RESSTR(SID_UNDO == GetSlotId() ? |