loplugin:stringadd in basctl..cui
Change-Id: I2fdeb7eb3ead3512ad6d3fe793305038ab3aa7ae Reviewed-on: https://gerrit.libreoffice.org/79886 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
This commit is contained in:
@@ -694,8 +694,7 @@ void DialogWindow::SaveDialog()
|
||||
{
|
||||
Sequence< OUString > aContentSeq = xSFI->getFolderContents( aURL, false );
|
||||
|
||||
OUString aDialogName_( aDialogName );
|
||||
aDialogName_ += "_" ;
|
||||
OUString aDialogName_ = aDialogName + "_" ;
|
||||
sal_Int32 nCount = aContentSeq.getLength();
|
||||
const OUString* pFiles = aContentSeq.getConstArray();
|
||||
for( int i = 0 ; i < nCount ; i++ )
|
||||
|
||||
@@ -3518,8 +3518,7 @@ void SbRtl_Shell(StarBASIC *, SbxArray & rPar, bool)
|
||||
OUString tmp = rPar.Get(3)->GetOUString().trim();
|
||||
if (!tmp.isEmpty())
|
||||
{
|
||||
aCmdLine += " ";
|
||||
aCmdLine += tmp;
|
||||
aCmdLine += " " + tmp;
|
||||
}
|
||||
}
|
||||
else if( aCmdLine.isEmpty() )
|
||||
|
||||
@@ -293,25 +293,25 @@ bool CppuOptions::initOptions(int ac, char* av[], bool bCmdFile)
|
||||
|
||||
OString CppuOptions::prepareHelp()
|
||||
{
|
||||
OString help("\nusing: ");
|
||||
help += m_program + " [-options] file_1 ... file_n\nOptions:\n"
|
||||
" -O<path> = path describes the root directory for the generated output.\n"
|
||||
" The output directory tree is generated under this directory.\n"
|
||||
" -T<name> = name specifies a type or a list of types. The output for this\n"
|
||||
" [t1;...] type is generated. If no '-T' option is specified,\n"
|
||||
" then output for all types is generated.\n"
|
||||
" Example: 'com.sun.star.uno.XInterface' is a valid type.\n"
|
||||
" -L = UNO type functions are generated lightweight, that means only\n"
|
||||
" the name and typeclass are given and everything else is retrieved\n"
|
||||
" from the type library dynamically. The default is that UNO type\n"
|
||||
" functions provides enough type information for bootstrapping C++.\n"
|
||||
" '-L' should be the default for external components.\n"
|
||||
" -C = UNO type functions are generated comprehensive that means all\n"
|
||||
" necessary information is available for bridging the type in UNO.\n"
|
||||
" -nD = no dependent types are generated.\n"
|
||||
" -G = generate only target files which does not exists.\n"
|
||||
" -Gc = generate only target files which content will be changed.\n"
|
||||
" -X<file> = extra types which will not be taken into account for generation.\n\n";
|
||||
OString help = "\nusing: " +
|
||||
m_program + " [-options] file_1 ... file_n\nOptions:\n"
|
||||
" -O<path> = path describes the root directory for the generated output.\n"
|
||||
" The output directory tree is generated under this directory.\n"
|
||||
" -T<name> = name specifies a type or a list of types. The output for this\n"
|
||||
" [t1;...] type is generated. If no '-T' option is specified,\n"
|
||||
" then output for all types is generated.\n"
|
||||
" Example: 'com.sun.star.uno.XInterface' is a valid type.\n"
|
||||
" -L = UNO type functions are generated lightweight, that means only\n"
|
||||
" the name and typeclass are given and everything else is retrieved\n"
|
||||
" from the type library dynamically. The default is that UNO type\n"
|
||||
" functions provides enough type information for bootstrapping C++.\n"
|
||||
" '-L' should be the default for external components.\n"
|
||||
" -C = UNO type functions are generated comprehensive that means all\n"
|
||||
" necessary information is available for bridging the type in UNO.\n"
|
||||
" -nD = no dependent types are generated.\n"
|
||||
" -G = generate only target files which does not exists.\n"
|
||||
" -Gc = generate only target files which content will be changed.\n"
|
||||
" -X<file> = extra types which will not be taken into account for generation.\n\n";
|
||||
help += prepareVersion();
|
||||
|
||||
return help;
|
||||
|
||||
@@ -223,18 +223,18 @@ bool JavaOptions::initOptions(int ac, char* av[], bool bCmdFile)
|
||||
|
||||
OString JavaOptions::prepareHelp()
|
||||
{
|
||||
OString help("\nusing: ");
|
||||
help += m_program + " [-options] file_1 ... file_n -Xfile_n+1 -Xfile_n+2\nOptions:\n"
|
||||
" -O<path> = path describes the root directory for the generated output.\n"
|
||||
" The output directory tree is generated under this directory.\n"
|
||||
" -T<name> = name specifies a type or a list of types. The output for this\n"
|
||||
" [t1;...] type and all dependent types are generated. If no '-T' option is\n"
|
||||
" specified, then output for all types is generated.\n"
|
||||
" Example: 'com.sun.star.uno.XInterface' is a valid type.\n"
|
||||
" -nD = no dependent types are generated.\n"
|
||||
" -G = generate only target files which does not exists.\n"
|
||||
" -Gc = generate only target files which content will be changed.\n"
|
||||
" -X<file> = extra types which will not be taken into account for generation.\n\n";
|
||||
OString help = "\nusing: " +
|
||||
m_program + " [-options] file_1 ... file_n -Xfile_n+1 -Xfile_n+2\nOptions:\n"
|
||||
" -O<path> = path describes the root directory for the generated output.\n"
|
||||
" The output directory tree is generated under this directory.\n"
|
||||
" -T<name> = name specifies a type or a list of types. The output for this\n"
|
||||
" [t1;...] type and all dependent types are generated. If no '-T' option is\n"
|
||||
" specified, then output for all types is generated.\n"
|
||||
" Example: 'com.sun.star.uno.XInterface' is a valid type.\n"
|
||||
" -nD = no dependent types are generated.\n"
|
||||
" -G = generate only target files which does not exists.\n"
|
||||
" -Gc = generate only target files which content will be changed.\n"
|
||||
" -X<file> = extra types which will not be taken into account for generation.\n\n";
|
||||
help += prepareVersion();
|
||||
|
||||
return help;
|
||||
@@ -242,9 +242,7 @@ OString JavaOptions::prepareHelp()
|
||||
|
||||
OString JavaOptions::prepareVersion() const
|
||||
{
|
||||
OString version(m_program);
|
||||
version += " Version 2.0\n\n";
|
||||
return version;
|
||||
return m_program + " Version 2.0\n\n";
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -187,14 +187,11 @@ namespace
|
||||
|
||||
if (!rURL.isEmpty() && !rName.isEmpty())
|
||||
{
|
||||
aRetval = rURL;
|
||||
aRetval += "/";
|
||||
aRetval += rName;
|
||||
aRetval = rURL + "/" + rName;
|
||||
|
||||
if (!rExt.isEmpty())
|
||||
{
|
||||
aRetval += ".";
|
||||
aRetval += rExt;
|
||||
aRetval += "." + rExt;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -207,10 +204,7 @@ namespace
|
||||
|
||||
if (!rURL.isEmpty() && !rName.isEmpty())
|
||||
{
|
||||
aRetval = rURL;
|
||||
aRetval += "/";
|
||||
aRetval += rName;
|
||||
aRetval += ".pack";
|
||||
aRetval = rURL + "/" + rName + ".pack";
|
||||
}
|
||||
|
||||
return aRetval;
|
||||
@@ -309,8 +303,7 @@ namespace
|
||||
|
||||
if (!file.second.isEmpty())
|
||||
{
|
||||
aNewFileURL += ".";
|
||||
aNewFileURL += file.second;
|
||||
aNewFileURL += "." + file.second;
|
||||
}
|
||||
|
||||
bError |= (osl::FileBase::E_None != osl::File::remove(aNewFileURL));
|
||||
@@ -368,8 +361,7 @@ namespace
|
||||
|
||||
if (!file.second.isEmpty())
|
||||
{
|
||||
aSourceFileURL += ".";
|
||||
aSourceFileURL += file.second;
|
||||
aSourceFileURL += "." + file.second;
|
||||
}
|
||||
|
||||
if (fileExists(aSourceFileURL))
|
||||
@@ -378,8 +370,7 @@ namespace
|
||||
|
||||
if (!file.second.isEmpty())
|
||||
{
|
||||
aTargetFileURL += ".";
|
||||
aTargetFileURL += file.second;
|
||||
aTargetFileURL += "." +file.second;
|
||||
}
|
||||
|
||||
if (fileExists(aTargetFileURL))
|
||||
|
||||
@@ -256,9 +256,7 @@ Reference<XConnection> SAL_CALL ODriverDelegator::connect(const OUString& url,
|
||||
sCuttedUrl += "?";
|
||||
else
|
||||
sCuttedUrl += "&";
|
||||
sCuttedUrl += sAdd;
|
||||
sCuttedUrl += "characterEncoding=";
|
||||
sCuttedUrl += sIanaName;
|
||||
sCuttedUrl += sAdd + "characterEncoding=" + sIanaName;
|
||||
}
|
||||
}
|
||||
} // if ( !bIsODBC )
|
||||
|
||||
@@ -207,8 +207,7 @@ void SAL_CALL OMySQLTable::alterColumnByName(const OUString& colName,
|
||||
{
|
||||
if (sTypeName.indexOf(s_sAutoIncrement) == -1)
|
||||
{
|
||||
sTypeName += " ";
|
||||
sTypeName += s_sAutoIncrement;
|
||||
sTypeName += OUStringLiteral(" ") + s_sAutoIncrement;
|
||||
}
|
||||
}
|
||||
else
|
||||
|
||||
@@ -72,9 +72,7 @@ sdbcx::ObjectType OUsers::appendObject(const OUString& _rForName,
|
||||
>>= sPassword;
|
||||
if (!sPassword.isEmpty())
|
||||
{
|
||||
aSql += " IDENTIFIED BY '";
|
||||
aSql += sPassword;
|
||||
aSql += "'";
|
||||
aSql += " IDENTIFIED BY '" + sPassword + "'";
|
||||
}
|
||||
|
||||
Reference<XStatement> xStmt = m_xConnection->createStatement();
|
||||
|
||||
@@ -241,8 +241,7 @@ SQLRETURN OConnection::Construct(const OUString& url,const Sequence< PropertyVal
|
||||
{
|
||||
if( ! (pBegin->Value >>= aSysDrvSettings) )
|
||||
SAL_WARN("connectivity.odbc", "Construct: unable to get property SystemDriverSettings");
|
||||
aDSN += ";";
|
||||
aDSN += aSysDrvSettings;
|
||||
aDSN += ";" + aSysDrvSettings;
|
||||
}
|
||||
else if( pBegin->Name == "CharSet")
|
||||
{
|
||||
|
||||
@@ -854,8 +854,7 @@ void ODatabaseMetaDataResultSet::openTables(const Any& catalog, const OUString&
|
||||
const OUString* pEnd = pBegin + types.getLength();
|
||||
for(;pBegin != pEnd;++pBegin)
|
||||
{
|
||||
aCOL += OUStringToOString(*pBegin,m_nTextEncoding);
|
||||
aCOL += pComma;
|
||||
aCOL += OUStringToOString(*pBegin,m_nTextEncoding) + pComma;
|
||||
}
|
||||
if ( !aCOL.isEmpty() )
|
||||
{
|
||||
|
||||
@@ -106,8 +106,7 @@ namespace
|
||||
*/
|
||||
OUString SetQuotation(const OUString& rValue, const OUString& rQuot, const OUString& rQuotToReplace)
|
||||
{
|
||||
OUString rNewValue = rQuot;
|
||||
rNewValue += rValue;
|
||||
OUString rNewValue = rQuot + rValue;
|
||||
sal_Int32 nIndex = sal_Int32(-1); // Replace quotes with double quotes or the parser gets into problems
|
||||
|
||||
if (!rQuot.isEmpty())
|
||||
|
||||
@@ -119,8 +119,7 @@ extern "C" void SAL_CALL uno_getCurrentEnvironment(uno_Environment ** ppEnv, rtl
|
||||
|
||||
if (pTypeName && rtl_uString_getLength(pTypeName))
|
||||
{
|
||||
OUString envDcp(pTypeName);
|
||||
envDcp += currPurpose;
|
||||
OUString envDcp = OUString(pTypeName) + currPurpose;
|
||||
|
||||
uno_getEnvironment(ppEnv, envDcp.pData, nullptr);
|
||||
}
|
||||
@@ -202,9 +201,7 @@ static int s_getNextEnv(uno_Environment ** ppEnv, uno_Environment * pCurrEnv, un
|
||||
|
||||
if (!nextPurpose.isEmpty())
|
||||
{
|
||||
OUString next_envDcp(UNO_LB_UNO);
|
||||
next_envDcp += nextPurpose;
|
||||
|
||||
OUString next_envDcp = UNO_LB_UNO + nextPurpose;
|
||||
uno_getEnvironment(ppEnv, next_envDcp.pData, nullptr);
|
||||
}
|
||||
else
|
||||
|
||||
@@ -231,8 +231,7 @@ void getCascadeMapping(uno_Mapping ** ppMapping,
|
||||
{
|
||||
OUString purpose = getPrefix(from_envPurpose, to_envPurpose);
|
||||
|
||||
OUString uno_envDcp = uno_envType;
|
||||
uno_envDcp += purpose;
|
||||
OUString uno_envDcp = uno_envType + purpose;
|
||||
|
||||
// direct mapping possible?
|
||||
// uno:bla-->uno:bla:blubb
|
||||
@@ -268,17 +267,13 @@ void getCascadeMapping(uno_Mapping ** ppMapping,
|
||||
else if (from_envType != uno_envType && to_envType == uno_envType) // <ANY> -> UNO ?
|
||||
// mediate via uno:purpose(fromEnv)
|
||||
{
|
||||
OUString envDcp = uno_envType;
|
||||
|
||||
envDcp += from_envPurpose;
|
||||
OUString envDcp = uno_envType + from_envPurpose;
|
||||
uno_getEnvironment(&pInterm, envDcp.pData, nullptr);
|
||||
}
|
||||
else if (from_envType == uno_envType && to_envType != uno_envType) // UNO -> <ANY>?
|
||||
// mediate via uno(context)
|
||||
{
|
||||
OUString envDcp = uno_envType;
|
||||
|
||||
envDcp += to_envPurpose;
|
||||
OUString envDcp = uno_envType + to_envPurpose;
|
||||
uno_getEnvironment(&pInterm, envDcp.pData, nullptr);
|
||||
}
|
||||
else // everything else
|
||||
@@ -286,8 +281,7 @@ void getCascadeMapping(uno_Mapping ** ppMapping,
|
||||
{
|
||||
OUString purpose = getPrefix(from_envPurpose, to_envPurpose);
|
||||
|
||||
OUString uno_envDcp = uno_envType;
|
||||
uno_envDcp += purpose;
|
||||
OUString uno_envDcp = uno_envType + purpose;
|
||||
|
||||
uno_getEnvironment(&pInterm, uno_envDcp.pData, nullptr);
|
||||
}
|
||||
|
||||
@@ -931,9 +931,9 @@ void EnvironmentsData::registerEnvironment( uno_Environment ** ppEnv )
|
||||
OSL_ENSURE( ppEnv, "### null ptr!" );
|
||||
uno_Environment * pEnv = *ppEnv;
|
||||
|
||||
OUString aKey(
|
||||
OUString::number( reinterpret_cast< sal_IntPtr >(pEnv->pContext) ) );
|
||||
aKey += pEnv->pTypeName;
|
||||
OUString aKey =
|
||||
OUString::number( reinterpret_cast< sal_IntPtr >(pEnv->pContext) ) +
|
||||
OUString(pEnv->pTypeName);
|
||||
|
||||
// try to find registered environment
|
||||
OUString2EnvironmentMap::const_iterator const iFind(
|
||||
|
||||
@@ -196,8 +196,7 @@ sal_uInt32 SvxConfigPageHelper::generateRandomValue()
|
||||
|
||||
OUString SvxConfigPageHelper::generateCustomURL( SvxEntries* entries )
|
||||
{
|
||||
OUString url = ITEM_TOOLBAR_URL;
|
||||
url += CUSTOM_TOOLBAR_STR;
|
||||
OUString url = OUStringLiteral(ITEM_TOOLBAR_URL) + CUSTOM_TOOLBAR_STR;
|
||||
|
||||
// use a random number to minimize possible clash with existing custom toolbars
|
||||
url += OUString::number( generateRandomValue(), 16 );
|
||||
|
||||
@@ -114,8 +114,7 @@ OUString SvxHyperlinkDocTp::GetCurrentURL () const
|
||||
|
||||
if( !aStrMark.isEmpty() )
|
||||
{
|
||||
aStrURL += sHash;
|
||||
aStrURL += aStrMark;
|
||||
aStrURL += sHash + aStrMark;
|
||||
}
|
||||
|
||||
return aStrURL;
|
||||
|
||||
@@ -642,8 +642,7 @@ void SvxGrfCropPage::GraphicHasChanged( bool bFound )
|
||||
(static_cast<float>(aOrigSize.Width())/TWIP_TO_INCH)+0.5));
|
||||
sal_Int32 ay = sal_Int32(floor(static_cast<float>(aOrigPixelSize.Height()) /
|
||||
(static_cast<float>(aOrigSize.Height())/TWIP_TO_INCH)+0.5));
|
||||
sTemp += " ";
|
||||
sTemp += CuiResId( RID_SVXSTR_PPI );
|
||||
sTemp += " " + CuiResId( RID_SVXSTR_PPI );
|
||||
OUString sPPI = OUString::number(ax);
|
||||
if (abs(ax - ay) > 1) {
|
||||
sPPI += OUStringLiteral1(0x00D7) + OUString::number(ay);
|
||||
|
||||
@@ -144,8 +144,7 @@ void SvxGradientTabPage::ActivatePage( const SfxItemSet& rSet )
|
||||
|
||||
// determining (and possibly cutting) the name and
|
||||
// displaying it in the GroupBox
|
||||
OUString aString( CuiResId( RID_SVXSTR_TABLE ) );
|
||||
aString += ": ";
|
||||
OUString aString = CuiResId( RID_SVXSTR_TABLE ) + ": ";
|
||||
INetURLObject aURL( m_pGradientList->GetPath() );
|
||||
|
||||
aURL.Append( m_pGradientList->GetName() );
|
||||
|
||||
@@ -145,8 +145,7 @@ void SvxHatchTabPage::ActivatePage( const SfxItemSet& rSet )
|
||||
|
||||
// determining (possibly cutting) the name
|
||||
// and displaying it in the GroupBox
|
||||
OUString aString( CuiResId( RID_SVXSTR_TABLE ) );
|
||||
aString += ": ";
|
||||
OUString aString = CuiResId( RID_SVXSTR_TABLE ) + ": ";
|
||||
INetURLObject aURL( m_pHatchingList->GetPath() );
|
||||
|
||||
aURL.Append( m_pHatchingList->GetName() );
|
||||
|
||||
@@ -142,8 +142,7 @@ void SvxPatternTabPage::ActivatePage( const SfxItemSet& rSet )
|
||||
|
||||
// determining (possibly cutting) the name and
|
||||
// displaying it in the GroupBox
|
||||
OUString aString( CuiResId( RID_SVXSTR_TABLE ) );
|
||||
aString += ": ";
|
||||
OUString aString = CuiResId( RID_SVXSTR_TABLE ) + ": ";
|
||||
INetURLObject aURL( m_pPatternList->GetPath() );
|
||||
|
||||
aURL.Append( m_pPatternList->GetName() );
|
||||
|
||||
Reference in New Issue
Block a user