From 687932bc898a8a7d6fbf68260cefe789eec9aadf Mon Sep 17 00:00:00 2001 From: Matteo Casalin Date: Sun, 27 Jan 2019 19:44:56 +0100 Subject: Use indexed getToken() Change-Id: I0977533e71e070227e19555d140d1de307bf91f4 Reviewed-on: https://gerrit.libreoffice.org/67307 Tested-by: Jenkins Reviewed-by: Matteo Casalin --- sw/source/ui/misc/glossary.cxx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'sw') diff --git a/sw/source/ui/misc/glossary.cxx b/sw/source/ui/misc/glossary.cxx index ba79e0d072cc..43c616deece3 100644 --- a/sw/source/ui/misc/glossary.cxx +++ b/sw/source/ui/misc/glossary.cxx @@ -690,13 +690,14 @@ void SwGlossaryDlg::Init() OUString sGroupName(pGlossaryHdl->GetGroupName(nId, &sTitle)); if(sGroupName.isEmpty()) continue; - const OUString sName{ sGroupName.getToken( 0, GLOS_DELIM ) }; + sal_Int32 nIdx{ 0 }; + const OUString sName{ sGroupName.getToken( 0, GLOS_DELIM, nIdx ) }; if(sTitle.isEmpty()) sTitle = sName; if(sTitle == sMyAutoTextEnglish) sTitle = sMyAutoTextTranslated; SvTreeListEntry* pEntry = m_pCategoryBox->InsertEntry( sTitle ); - const sal_Int32 nPath = sGroupName.getToken( 1, GLOS_DELIM ).toInt32(); + const sal_Int32 nPath = sGroupName.getToken( 0, GLOS_DELIM, nIdx ).toInt32(); GroupUserData* pData = new GroupUserData; pData->sGroupName = sName; -- cgit