summaryrefslogtreecommitdiff
path: root/sfx2/source/dialog/templdlg.cxx
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2018-07-28 18:01:57 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-07-30 11:06:14 +0200
commit70bfdd828b01e9db0713b87645ffe39f3dc21c7e (patch)
treeb53e22d4c582e7cad6155f2c0c2536241cadb0f5 /sfx2/source/dialog/templdlg.cxx
parentdead246b1955a99b66b0a69e8da3db1a61f3ab88 (diff)
loplugin:stringloop in sfx2..svx
Change-Id: Ie4ca2421f00259f974b6d94f883adfa11600b1fe Reviewed-on: https://gerrit.libreoffice.org/58251 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sfx2/source/dialog/templdlg.cxx')
-rw-r--r--sfx2/source/dialog/templdlg.cxx10
1 files changed, 5 insertions, 5 deletions
diff --git a/sfx2/source/dialog/templdlg.cxx b/sfx2/source/dialog/templdlg.cxx
index 118389f77427..4b68f20dd4e6 100644
--- a/sfx2/source/dialog/templdlg.cxx
+++ b/sfx2/source/dialog/templdlg.cxx
@@ -1842,8 +1842,8 @@ void SfxCommonTemplateDialog_Impl::DeleteHdl()
SvTreeListEntry* pEntry = pTreeBox->IsVisible() ? pTreeBox->FirstSelected() : aFmtLb->FirstSelected();
const SfxStyleFamilyItem* pItem = GetFamilyItem_Impl();
- OUString aMsg = SfxResId(STR_DELETE_STYLE_USED)
- + SfxResId(STR_DELETE_STYLE);
+ OUStringBuffer aMsg;
+ aMsg.append(SfxResId(STR_DELETE_STYLE_USED)).append(SfxResId(STR_DELETE_STYLE));
while (pEntry)
{
@@ -1856,8 +1856,8 @@ void SfxCommonTemplateDialog_Impl::DeleteHdl()
if ( pStyle->IsUsed() ) // pStyle is in use in the document?
{
if (bUsedStyle) // add a separator for the second and later styles
- aMsg += ", ";
- aMsg += aTemplName;
+ aMsg.append(", ");
+ aMsg.append(aTemplName);
bUsedStyle = true;
}
@@ -1871,7 +1871,7 @@ void SfxCommonTemplateDialog_Impl::DeleteHdl()
{
std::unique_ptr<weld::MessageDialog> xBox(Application::CreateMessageDialog(GetFrameWeld(),
VclMessageType::Question, VclButtonsType::YesNo,
- aMsg));
+ aMsg.makeStringAndClear()));
aApproved = xBox->run() == RET_YES;
}