summaryrefslogtreecommitdiff
path: root/cui/source/options/optlingu.cxx
diff options
context:
space:
mode:
authorJulien Nabet <serval2412@yahoo.fr>2018-02-27 22:34:17 +0100
committerJulien Nabet <serval2412@yahoo.fr>2018-02-28 11:02:12 +0100
commit81260c448911069ce8cb051d3a973ec52b9b43a3 (patch)
tree2c18396c931db3f78f21e813fd9307ea5405b85b /cui/source/options/optlingu.cxx
parentb6aee26f3630fd531e51f781391ba0130001df60 (diff)
Use for-range loops in cui
Change-Id: I82cbea6d221ec0fd0e0d4620bdda698f2bed520e Reviewed-on: https://gerrit.libreoffice.org/50472 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
Diffstat (limited to 'cui/source/options/optlingu.cxx')
-rw-r--r--cui/source/options/optlingu.cxx26
1 files changed, 12 insertions, 14 deletions
diff --git a/cui/source/options/optlingu.cxx b/cui/source/options/optlingu.cxx
index 12f641aa5151..7c7d1f501ba4 100644
--- a/cui/source/options/optlingu.cxx
+++ b/cui/source/options/optlingu.cxx
@@ -1076,14 +1076,12 @@ bool SvxLinguTabPage::FillItemSet( SfxItemSet* rCoreSet )
if (!pLinguData)
pLinguData = new SvxLinguData_Impl;
- LangImplNameTable::const_iterator aIt;
-
// update spellchecker configuration entries
const LangImplNameTable *pTable = &pLinguData->GetSpellTable();
- for (aIt = pTable->begin(); aIt != pTable->end(); ++aIt)
+ for (auto const& elem : *pTable)
{
- LanguageType nLang = aIt->first;
- const Sequence< OUString > aImplNames( aIt->second );
+ LanguageType nLang = elem.first;
+ const Sequence< OUString > aImplNames(elem.second);
uno::Reference< XLinguServiceManager2 > xMgr( pLinguData->GetManager() );
Locale aLocale( LanguageTag::convertToLocale(nLang) );
if (xMgr.is())
@@ -1092,10 +1090,10 @@ bool SvxLinguTabPage::FillItemSet( SfxItemSet* rCoreSet )
// update grammar checker configuration entries
pTable = &pLinguData->GetGrammarTable();
- for (aIt = pTable->begin(); aIt != pTable->end(); ++aIt)
+ for (auto const& elem : *pTable)
{
- LanguageType nLang = aIt->first;
- const Sequence< OUString > aImplNames( aIt->second );
+ LanguageType nLang = elem.first;
+ const Sequence< OUString > aImplNames(elem.second);
uno::Reference< XLinguServiceManager2 > xMgr( pLinguData->GetManager() );
Locale aLocale( LanguageTag::convertToLocale(nLang) );
if (xMgr.is())
@@ -1104,10 +1102,10 @@ bool SvxLinguTabPage::FillItemSet( SfxItemSet* rCoreSet )
// update hyphenator configuration entries
pTable = &pLinguData->GetHyphTable();
- for (aIt = pTable->begin(); aIt != pTable->end(); ++aIt)
+ for (auto const& elem : *pTable)
{
- LanguageType nLang = aIt->first;
- const Sequence< OUString > aImplNames( aIt->second );
+ LanguageType nLang = elem.first;
+ const Sequence< OUString > aImplNames(elem.second);
uno::Reference< XLinguServiceManager2 > xMgr( pLinguData->GetManager() );
Locale aLocale( LanguageTag::convertToLocale(nLang) );
if (xMgr.is())
@@ -1116,10 +1114,10 @@ bool SvxLinguTabPage::FillItemSet( SfxItemSet* rCoreSet )
// update thesaurus configuration entries
pTable = &pLinguData->GetThesTable();
- for (aIt = pTable->begin(); aIt != pTable->end(); ++aIt)
+ for (auto const& elem : *pTable)
{
- LanguageType nLang = aIt->first;
- const Sequence< OUString > aImplNames( aIt->second );
+ LanguageType nLang = elem.first;
+ const Sequence< OUString > aImplNames(elem.second);
uno::Reference< XLinguServiceManager2 > xMgr( pLinguData->GetManager() );
Locale aLocale( LanguageTag::convertToLocale(nLang) );
if (xMgr.is())