[Libreoffice-commits] core.git: sw/source
Libreoffice Gerrit user
logerrit at kemper.freedesktop.org
Mon Feb 4 21:05:54 UTC 2019
sw/source/ui/fldui/fldref.cxx | 11 ++++-------
1 file changed, 4 insertions(+), 7 deletions(-)
New commits:
commit c8adf591c724330aa999dfbdeacd94b470f59108
Author: Matteo Casalin <matteo.casalin at yahoo.com>
AuthorDate: Wed Jan 30 07:58:28 2019 +0100
Commit: Matteo Casalin <matteo.casalin at yahoo.com>
CommitDate: Mon Feb 4 22:05:33 2019 +0100
Reduce temporaries
Change-Id: I50c22563c7804efe0dd125468d13e81b41b23702
Reviewed-on: https://gerrit.libreoffice.org/67317
Tested-by: Jenkins
Reviewed-by: Matteo Casalin <matteo.casalin at yahoo.com>
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;
More information about the Libreoffice-commits
mailing list