cui/source/customize/cfg.cxx | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-)
New commits: commit 51e05acf07093ac8f2b2dc8eeb86abe9446e3463 Author: Julien Nabet <serval2...@yahoo.fr> Date: Sat Mar 30 22:09:09 2013 +0100 Simplify a bit iterators stuff Change-Id: Ie2159d5eb8caf3d8f13d9c1ec49cc2bb6a0d94eb diff --git a/cui/source/customize/cfg.cxx b/cui/source/customize/cfg.cxx index 0392d1f..6349796 100644 --- a/cui/source/customize/cfg.cxx +++ b/cui/source/customize/cfg.cxx @@ -2068,12 +2068,10 @@ SvTreeListEntry* SvxConfigPage::AddFunction( // check that this function is not already in the menu SvxConfigEntry* pParent = GetTopLevelSelection(); - SvxEntries::const_iterator iter = pParent->GetEntries()->begin(); - SvxEntries::const_iterator end = pParent->GetEntries()->end(); - if ( !bAllowDuplicates ) { - while ( iter != end ) + for (SvxEntries::const_iterator iter(pParent->GetEntries()->begin()), end(pParent->GetEntries()->end()); + iter != end ; ++iter) { SvxConfigEntry *pCurEntry = *iter; @@ -2085,8 +2083,6 @@ SvTreeListEntry* SvxConfigPage::AddFunction( delete pNewEntryData; return NULL; } - - ++iter; } } _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits