diff options
author | Matteo Casalin <matteo.casalin@yahoo.com> | 2018-11-07 22:45:56 +0100 |
---|---|---|
committer | Matteo Casalin <matteo.casalin@yahoo.com> | 2018-11-10 22:04:04 +0100 |
commit | 81b507808baab2274e35f4602ebecf0913e81a74 (patch) | |
tree | b46fb53f1f6480cbaf4b456377eee03eec37fd2b /sfx2 | |
parent | e0c656aa3f6a1bb0783e059ad649c8a55edefc4b (diff) |
Use already available start index of substring
Change-Id: Ibaa2835e73dc42a7296e4749fdfbd05e282e04eb
Diffstat (limited to 'sfx2')
-rw-r--r-- | sfx2/source/bastyp/sfxhtml.cxx | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/sfx2/source/bastyp/sfxhtml.cxx b/sfx2/source/bastyp/sfxhtml.cxx index fc418a93d42a..f91bd5e59de2 100644 --- a/sfx2/source/bastyp/sfxhtml.cxx +++ b/sfx2/source/bastyp/sfxhtml.cxx @@ -324,10 +324,9 @@ double SfxHTMLParser::GetTableDataOptionsValNum( sal_uInt32& nNumForm, (void)rFormatter.IsNumberFormat(aValStr, nParseForm, fVal); if ( comphelper::string::getTokenCount(aNumStr, ';') > 2 ) { - eNumLang = LanguageType(aNumStr.getToken( 1, ';' ).toInt32()); - sal_Int32 nPos = aNumStr.indexOf( ';' ); - nPos = aNumStr.indexOf( ';', nPos + 1 ); - OUString aFormat( aNumStr.copy( nPos + 1 ) ); + sal_Int32 nIdx {0}; + eNumLang = LanguageType(aNumStr.getToken( 1, ';', nIdx ).toInt32()); + OUString aFormat( aNumStr.copy( nIdx ) ); sal_Int32 nCheckPos; SvNumFormatType nType; if ( eNumLang != LANGUAGE_SYSTEM ) |