summaryrefslogtreecommitdiff
path: root/cui
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2019-08-19 15:11:27 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2019-08-19 19:28:11 +0200
commit8efd46ed867b66f9fbc31dbaa1d46bc91ea29ae2 (patch)
treeeafc8ade307c5fe797fdddddfa6d9dc39c935b8a /cui
parent9c10e29287740f473fa4f33ac6188b8c8543bfbb (diff)
loplugin:constvars in cppuhelper..desktop
Change-Id: Iaf42114ab98875c4bc1545684f1893540b998ef2 Reviewed-on: https://gerrit.libreoffice.org/77723 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'cui')
-rw-r--r--cui/source/dialogs/FontFeaturesDialog.cxx2
-rw-r--r--cui/source/dialogs/cuigaldlg.cxx4
-rw-r--r--cui/source/dialogs/iconcdlg.cxx2
-rw-r--r--cui/source/dialogs/thesdlg.cxx2
-rw-r--r--cui/source/options/optupdt.cxx4
-rw-r--r--cui/source/tabpages/autocdlg.cxx4
-rw-r--r--cui/source/tabpages/numpages.cxx2
7 files changed, 10 insertions, 10 deletions
diff --git a/cui/source/dialogs/FontFeaturesDialog.cxx b/cui/source/dialogs/FontFeaturesDialog.cxx
index 21f962ee4b07..957a2c8e1228 100644
--- a/cui/source/dialogs/FontFeaturesDialog.cxx
+++ b/cui/source/dialogs/FontFeaturesDialog.cxx
@@ -172,7 +172,7 @@ OUString FontFeaturesDialog::createFontNameWithFeatures()
OUStringBuffer sNameSuffix;
bool bFirst = true;
- for (FontFeatureItem& rItem : m_aFeatureItems)
+ for (const FontFeatureItem& rItem : m_aFeatureItems)
{
if (rItem.m_xCheck->get_visible())
{
diff --git a/cui/source/dialogs/cuigaldlg.cxx b/cui/source/dialogs/cuigaldlg.cxx
index 4b220800d33c..a90ef52b916a 100644
--- a/cui/source/dialogs/cuigaldlg.cxx
+++ b/cui/source/dialogs/cuigaldlg.cxx
@@ -720,7 +720,7 @@ void TPGalleryThemeProperties::FillFilterList()
::avmedia::FilterNameVector aFilters;
::avmedia::MediaWindow::getMediaFilters( aFilters );
- for(std::pair<OUString,OUString> & aFilter : aFilters)
+ for(const std::pair<OUString,OUString> & aFilter : aFilters)
{
for( sal_Int32 nIndex = 0; nIndex >= 0; )
{
@@ -760,7 +760,7 @@ void TPGalleryThemeProperties::FillFilterList()
#if HAVE_FEATURE_AVMEDIA
// media filters
- for(std::pair<OUString,OUString> & aFilter : aFilters)
+ for(const std::pair<OUString,OUString> & aFilter : aFilters)
{
for( sal_Int32 nIndex = 0; nIndex >= 0; )
{
diff --git a/cui/source/dialogs/iconcdlg.cxx b/cui/source/dialogs/iconcdlg.cxx
index 06c4a37a5397..39864c3a3d3b 100644
--- a/cui/source/dialogs/iconcdlg.cxx
+++ b/cui/source/dialogs/iconcdlg.cxx
@@ -292,7 +292,7 @@ void SvxHpLinkDlg::Start_Impl()
IconChoicePageData* SvxHpLinkDlg::GetPageData ( const OString& rId )
{
IconChoicePageData *pRet = nullptr;
- for (auto & pData : maPageList)
+ for (const auto & pData : maPageList)
{
if ( pData->sId == rId )
{
diff --git a/cui/source/dialogs/thesdlg.cxx b/cui/source/dialogs/thesdlg.cxx
index 2a5f73c43175..1ed20384016c 100644
--- a/cui/source/dialogs/thesdlg.cxx
+++ b/cui/source/dialogs/thesdlg.cxx
@@ -294,7 +294,7 @@ SvxThesaurusDialog::SvxThesaurusDialog(
}
std::sort( aLangVec.begin(), aLangVec.end() );
m_xLangLB->freeze();
- for (OUString & i : aLangVec)
+ for (const OUString & i : aLangVec)
m_xLangLB->append_text(i);
m_xLangLB->thaw();
diff --git a/cui/source/options/optupdt.cxx b/cui/source/options/optupdt.cxx
index 6f308bd6455d..4621ac787d95 100644
--- a/cui/source/options/optupdt.cxx
+++ b/cui/source/options/optupdt.cxx
@@ -158,10 +158,10 @@ void SvxOnlineUpdateTabPage::UpdateUserAgent()
OUString aPseudoURL = "useragent:normal";
if( m_xExtrasCheckBox->get_active() )
aPseudoURL = "useragent:extended";
- uno::Sequence< beans::StringPair > aHeaders
+ const uno::Sequence< beans::StringPair > aHeaders
= xDav->getUserRequestHeaders( aPseudoURL, ucb::WebDAVHTTPMethod(0) );
- for (css::beans::StringPair & aHeader : aHeaders)
+ for (const css::beans::StringPair & aHeader : aHeaders)
{
if ( aHeader.First == "User-Agent" )
{
diff --git a/cui/source/tabpages/autocdlg.cxx b/cui/source/tabpages/autocdlg.cxx
index 8edc8430f751..b2b38f74f852 100644
--- a/cui/source/tabpages/autocdlg.cxx
+++ b/cui/source/tabpages/autocdlg.cxx
@@ -751,13 +751,13 @@ bool OfaAutocorrReplacePage::FillItemSet( SfxItemSet* )
std::vector<SvxAutocorrWord> aDeleteWords;
std::vector<SvxAutocorrWord> aNewWords;
- for (DoubleString & deleteEntry : rStringChangeList.aDeletedEntries)
+ for (const DoubleString & deleteEntry : rStringChangeList.aDeletedEntries)
{
SvxAutocorrWord aDeleteWord( deleteEntry.sShort, deleteEntry.sLong );
aDeleteWords.push_back( aDeleteWord );
}
- for (DoubleString & newEntry : rStringChangeList.aNewEntries)
+ for (const DoubleString & newEntry : rStringChangeList.aNewEntries)
{
//fdo#67697 if the user data is set then we want to retain the
//source formatting of the entry, so don't use the optimized
diff --git a/cui/source/tabpages/numpages.cxx b/cui/source/tabpages/numpages.cxx
index 89c43731389a..d366fb1a90bc 100644
--- a/cui/source/tabpages/numpages.cxx
+++ b/cui/source/tabpages/numpages.cxx
@@ -1914,7 +1914,7 @@ IMPL_LINK_NOARG(SvxNumOptionsTabPage, PopupActivateHdl_Impl, weld::ToggleButton&
OUString sGrfName;
ScopedVclPtrInstance< VirtualDevice > pVD;
size_t i = 0;
- for (auto & grfName : aGrfNames)
+ for (const auto & grfName : aGrfNames)
{
sGrfName = grfName;
OUString sItemId = "gallery" + OUString::number(i);