summaryrefslogtreecommitdiff
path: root/extensions
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2019-10-30 20:27:26 +0100
committerStephan Bergmann <sbergman@redhat.com>2019-10-31 09:14:39 +0100
commitd526bd7dd5b94be6fe5a823372da1facca3d43fa (patch)
tree656b49726096326e7832cde5c177f85fd8c8c454 /extensions
parent7eeb484e7d1faf87fbb8774a8bda4328d047dde3 (diff)
Fix StringAdd::isCompileTimeConstant
...to find StringLiteral on the RHS of +=. Which revealed that the VisitCompoundStmt/checkForCompoundAssign logic needed to be fixed, too, so that s += side_effect(); s += "literal"; s += side_effect(); only gets combined to s += side_effect() + "literal"; s += side_effect(); and not all the way to s += side_effect() + "literal" + side_effect(); Change-Id: I432e3458b933a7d0ad6141c747b675cc8b0f0ba4 Reviewed-on: https://gerrit.libreoffice.org/81804 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'extensions')
-rw-r--r--extensions/source/propctrlr/eformshelper.cxx3
-rw-r--r--extensions/source/scanner/sanedlg.cxx9
2 files changed, 4 insertions, 8 deletions
diff --git a/extensions/source/propctrlr/eformshelper.cxx b/extensions/source/propctrlr/eformshelper.cxx
index 686913645c4c..e3bf4bf07a53 100644
--- a/extensions/source/propctrlr/eformshelper.cxx
+++ b/extensions/source/propctrlr/eformshelper.cxx
@@ -539,8 +539,7 @@ namespace pcr
if ( xBinding.is() )
{
// find a nice name for it
- OUString sBaseName(PcrRes(RID_STR_BINDING_NAME));
- sBaseName += " ";
+ OUString sBaseName(PcrRes(RID_STR_BINDING_NAME) + " ");
OUString sNewName;
sal_Int32 nNumber = 1;
do
diff --git a/extensions/source/scanner/sanedlg.cxx b/extensions/source/scanner/sanedlg.cxx
index 06dfbb6fdb2a..2a5ad9ea23f3 100644
--- a/extensions/source/scanner/sanedlg.cxx
+++ b/extensions/source/scanner/sanedlg.cxx
@@ -1007,8 +1007,7 @@ void SaneDlg::EstablishQuantumRange()
mxQuantumRangeBox->set_active_text( OUString( pBuf, strlen(pBuf), osl_getThreadTextEncoding() ) );
}
mxQuantumRangeBox->show();
- OUString aText( mrSane.GetOptionName( mnCurrentOption ) );
- aText += " ";
+ OUString aText( mrSane.GetOptionName( mnCurrentOption ) + " " );
aText += mrSane.GetOptionUnitName( mnCurrentOption );
mxOptionDescTxt->set_label(aText);
mxOptionDescTxt->show();
@@ -1025,8 +1024,7 @@ void SaneDlg::EstablishNumericOption()
return;
char pBuf[256];
- OUString aText( mrSane.GetOptionName( mnCurrentOption ) );
- aText += " ";
+ OUString aText( mrSane.GetOptionName( mnCurrentOption ) + " " );
aText += mrSane.GetOptionUnitName( mnCurrentOption );
if( mfMin != mfMax )
{
@@ -1263,8 +1261,7 @@ bool SaneDlg::LoadState()
return false;
const char* pEnv = getenv("HOME");
- OUString aFileName = pEnv ? OUString(pEnv, strlen(pEnv), osl_getThreadTextEncoding() ) : OUString();
- aFileName += "/.so_sane_state";
+ OUString aFileName = (pEnv ? OUString(pEnv, strlen(pEnv), osl_getThreadTextEncoding() ) : OUString()) + "/.so_sane_state";
Config aConfig( aFileName );
if( ! aConfig.HasGroup( "SANE" ) )
return false;