summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorMatteo Casalin <matteo.casalin@yahoo.com>2019-01-30 07:58:28 +0100
committerMatteo Casalin <matteo.casalin@yahoo.com>2019-02-04 22:05:33 +0100
commitc8adf591c724330aa999dfbdeacd94b470f59108 (patch)
treec394ec19b151bf157f622d0a98929daf6bcfb4b0 /sw
parenta2d4d00cb34cb092ad3d226d086976991c0991cb (diff)
Reduce temporaries
Change-Id: I50c22563c7804efe0dd125468d13e81b41b23702 Reviewed-on: https://gerrit.libreoffice.org/67317 Tested-by: Jenkins Reviewed-by: Matteo Casalin <matteo.casalin@yahoo.com>
Diffstat (limited to 'sw')
-rw-r--r--sw/source/ui/fldui/fldref.cxx11
1 files changed, 4 insertions, 7 deletions
diff --git a/sw/source/ui/fldui/fldref.cxx b/sw/source/ui/fldui/fldref.cxx
index f52464c6e142..9680406df1ff 100644
--- a/sw/source/ui/fldui/fldref.cxx
+++ b/sw/source/ui/fldui/fldref.cxx
@@ -140,8 +140,7 @@ void SwFieldRefPage::dispose()
IMPL_LINK_NOARG(SwFieldRefPage, ModifyHdl_Impl, Edit&, void)
{
- OUString sFilter = comphelper::string::strip(m_pFilterED->GetText(), ' ');
- UpdateSubType(sFilter);
+ UpdateSubType(comphelper::string::strip(m_pFilterED->GetText(), ' '));
}
// #i83479#
@@ -269,12 +268,11 @@ void SwFieldRefPage::Reset(const SfxItemSet* )
if( !IsRefresh() )
{
sal_Int32 nIdx{ 0 };
- OUString sUserData = GetUserData();
+ const OUString sUserData = GetUserData();
if(!IsRefresh() && sUserData.getToken(0, ';', nIdx).
equalsIgnoreAsciiCase(USER_DATA_VERSION_1))
{
- OUString sVal = sUserData.getToken(0, ';', nIdx);
- const sal_uInt16 nVal = static_cast< sal_uInt16 >(sVal.toInt32());
+ const sal_uInt16 nVal = static_cast< sal_uInt16 >(sUserData.getToken(0, ';', nIdx).toInt32());
if(nVal != USHRT_MAX)
{
for(sal_Int32 i = 0; i < m_pTypeLB->GetEntryCount(); i++)
@@ -393,8 +391,7 @@ IMPL_LINK_NOARG(SwFieldRefPage, TypeHdl, ListBox&, void)
sal_uInt16 nTypeId = static_cast<sal_uInt16>(reinterpret_cast<sal_uLong>(m_pTypeLB->GetEntryData(GetTypeSel())));
// fill selection-ListBox
- OUString sFilter = comphelper::string::strip(m_pFilterED->GetText(), ' ');
- UpdateSubType(sFilter);
+ UpdateSubType(comphelper::string::strip(m_pFilterED->GetText(), ' '));
bool bName = false;
nFieldDlgFormatSel = 0;