From 6eb7870aa10144281ccbc4702770d8ce1ceb3e9a Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Mon, 30 Sep 2019 15:11:41 +0200 Subject: loplugin:stringadd in sc Change-Id: Idab16f785ca5e8954f8e50132938f6329106c927 Reviewed-on: https://gerrit.libreoffice.org/79891 Tested-by: Jenkins Reviewed-by: Noel Grandin --- scripting/source/dlgprov/dlgevtatt.cxx | 4 +--- scripting/source/stringresource/stringresource.cxx | 9 +++------ 2 files changed, 4 insertions(+), 9 deletions(-) (limited to 'scripting') diff --git a/scripting/source/dlgprov/dlgevtatt.cxx b/scripting/source/dlgprov/dlgevtatt.cxx index 5ec4f6fb4d8b..5523881fd59f 100644 --- a/scripting/source/dlgprov/dlgevtatt.cxx +++ b/scripting/source/dlgprov/dlgevtatt.cxx @@ -613,9 +613,7 @@ namespace dlgprov OUString aOUFinal; aOUFinal += aRes.copy( 0, nIndex ); - aOUFinal += aQuoteChar; - aOUFinal += aMethodName; - aOUFinal += aQuoteChar; + aOUFinal += aQuoteChar + aMethodName + aQuoteChar; aOUFinal += aRes.copy( nIndex + 2 ); std::unique_ptr xBox(Application::CreateMessageDialog(nullptr, diff --git a/scripting/source/stringresource/stringresource.cxx b/scripting/source/stringresource/stringresource.cxx index 0387890474fa..58a4bf3da3dd 100644 --- a/scripting/source/stringresource/stringresource.cxx +++ b/scripting/source/stringresource/stringresource.cxx @@ -1628,21 +1628,18 @@ static OUString implGetNameScemeForLocaleItem( const LocaleItem* pLocaleItem ) "StringResourcePersistenceImpl::implGetNameScemeForLocaleItem(): pLocaleItem == NULL" ); Locale aLocale = pLocaleItem->m_locale; - OUString aRetStr = aUnder; - aRetStr += aLocale.Language; + OUString aRetStr = aUnder + aLocale.Language; OUString aCountry = aLocale.Country; if( !aCountry.isEmpty() ) { - aRetStr += aUnder; - aRetStr += aCountry; + aRetStr += aUnder + aCountry; } OUString aVariant = aLocale.Variant; if( !aVariant.isEmpty() ) { - aRetStr += aUnder; - aRetStr += aVariant; + aRetStr += aUnder + aVariant; } return aRetStr; } -- cgit