summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatteo Casalin <matteo.casalin@yahoo.com>2019-02-01 07:28:20 +0100
committerMatteo Casalin <matteo.casalin@yahoo.com>2019-02-04 22:59:31 +0100
commitff0c58d360b1958d896b437035b81058a176d41f (patch)
tree93d895fa02945a2cf87e7e4d71e52203fae71152
parent395729260ddd6ff1c32a9ac7ef5c5b4651f0100d (diff)
Use indexed getToken()
Change-Id: I7f27f9a8023102c5e07fb45ed40e06ee862fccde Reviewed-on: https://gerrit.libreoffice.org/67322 Tested-by: Jenkins Reviewed-by: Matteo Casalin <matteo.casalin@yahoo.com>
-rw-r--r--sw/source/ui/fldui/flddb.cxx7
1 files changed, 4 insertions, 3 deletions
diff --git a/sw/source/ui/fldui/flddb.cxx b/sw/source/ui/fldui/flddb.cxx
index dff301af6ce1..56da644402fd 100644
--- a/sw/source/ui/fldui/flddb.cxx
+++ b/sw/source/ui/fldui/flddb.cxx
@@ -173,10 +173,11 @@ void SwFieldDBPage::Reset(const SfxItemSet*)
if( !IsRefresh() )
{
- OUString sUserData = GetUserData();
- if (sUserData.getToken(0, ';').equalsIgnoreAsciiCase(USER_DATA_VERSION_1))
+ const OUString sUserData = GetUserData();
+ sal_Int32 nIdx{ 0 };
+ if (sUserData.getToken(0, ';', nIdx).equalsIgnoreAsciiCase(USER_DATA_VERSION_1))
{
- const sal_uInt16 nVal = static_cast<sal_uInt16>(sUserData.getToken(1, ';').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)