summaryrefslogtreecommitdiff
path: root/sc/source/ui/app
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2023-03-25 19:30:24 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2023-03-26 11:24:13 +0000
commit86313f053315cd0ba896e494d7bac14d2279c9b4 (patch)
treecc76691f65cb5fa70e86d81293fcdbf0a74f0e76 /sc/source/ui/app
parent4938bbcd64e95c9b494bcc32e8a5be3706f00cfa (diff)
loplugin:stringadd in sc
after my patch to merge the bufferadd loplugin into stringadd Change-Id: Ifa70db5be4719fe66d3043e5e49403246f6aa8bd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/149582 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sc/source/ui/app')
-rw-r--r--sc/source/ui/app/inputhdl.cxx23
1 files changed, 11 insertions, 12 deletions
diff --git a/sc/source/ui/app/inputhdl.cxx b/sc/source/ui/app/inputhdl.cxx
index 8d310e1c94d5..f01c2e987b63 100644
--- a/sc/source/ui/app/inputhdl.cxx
+++ b/sc/source/ui/app/inputhdl.cxx
@@ -1411,8 +1411,7 @@ void ScInputHandler::ShowFuncList( const ::std::vector< OUString > & rFuncStrVec
OUString aFuncNameStr;
OUString aDescFuncNameStr;
- OStringBuffer aPayload;
- aPayload.append("[ ");
+ OStringBuffer aPayload("[ ");
for (const OUString& rFunc : rFuncStrVec)
{
if ( rFunc[rFunc.getLength()-1] == cParenthesesReplacement )
@@ -1434,16 +1433,16 @@ void ScInputHandler::ShowFuncList( const ::std::vector< OUString > & rFuncStrVec
{
if ( !ppFDesc->getFunctionName().isEmpty() )
{
- aPayload.append("{");
- aPayload.append("\"index\": ");
- aPayload.append(static_cast<sal_Int64>(nCurIndex));
- aPayload.append(", ");
- aPayload.append("\"signature\": \"");
- aPayload.append(escapeJSON(ppFDesc->getSignature()));
- aPayload.append("\", ");
- aPayload.append("\"description\": \"");
- aPayload.append(escapeJSON(ppFDesc->getDescription()));
- aPayload.append("\"}, ");
+ aPayload.append("{"
+ "\"index\": "
+ + OString::number(static_cast<sal_Int64>(nCurIndex))
+ + ", "
+ "\"signature\": \""
+ + escapeJSON(ppFDesc->getSignature())
+ + "\", "
+ "\"description\": \""
+ + escapeJSON(ppFDesc->getDescription())
+ + "\"}, ");
}
}
++nCurIndex;