diff options
author | Matteo Casalin <matteo.casalin@yahoo.com> | 2018-06-30 09:50:22 +0200 |
---|---|---|
committer | Matteo Casalin <matteo.casalin@yahoo.com> | 2018-06-30 23:00:18 +0200 |
commit | ba437fd59da07768826a1e816ba727109d3c5d3b (patch) | |
tree | 7be72d95863191c40323999995bd83de4408ba77 /svx | |
parent | e07a80e23bc8249a8bf1477aeed8e33f6c4c10be (diff) |
Avoid using getTokenCount() to get last token in a string
Change-Id: I1a2d181fdf03926452cb00f49490c9c4151dd8f9
Diffstat (limited to 'svx')
-rw-r--r-- | svx/source/gallery2/galbrws2.cxx | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/svx/source/gallery2/galbrws2.cxx b/svx/source/gallery2/galbrws2.cxx index 3570c4c703ed..4760f19dc235 100644 --- a/svx/source/gallery2/galbrws2.cxx +++ b/svx/source/gallery2/galbrws2.cxx @@ -18,7 +18,6 @@ */ -#include <comphelper/string.hxx> #include <sot/formats.hxx> #include <svl/urlbmk.hxx> #include <svl/stritem.hxx> @@ -1186,7 +1185,7 @@ OUString GalleryBrowser2::GetItemText( const GalleryTheme& rTheme, const SgaObje if( aTitle.isEmpty() ) { aTitle = aURL.GetMainURL( INetURLObject::DecodeMechanism::Unambiguous ); - aTitle = aTitle.getToken( comphelper::string::getTokenCount(aTitle, '/') - 1, '/' ); + aTitle = aTitle.copy( aTitle.lastIndexOf('/')+1 ); } aRet += aTitle; |