diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2022-04-04 11:14:11 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2022-05-05 12:57:00 +0200 |
commit | 9f1701d01d9f664828356976d8592492f85b30f5 (patch) | |
tree | a91eaef0674591af87b06096fdd186283559a8de /cui/source/customize | |
parent | b8bb44161aeb6e00526a38343b63e678ce7d4a1a (diff) |
use more o3tl::getToken
found by inspecting call sites of OUString::getToken
Change-Id: I4269c7476c7aa46fac39528227e350568f0eb34a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132644
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'cui/source/customize')
-rw-r--r-- | cui/source/customize/CustomNotebookbarGenerator.cxx | 3 | ||||
-rw-r--r-- | cui/source/customize/SvxNotebookbarConfigPage.cxx | 2 |
2 files changed, 3 insertions, 2 deletions
diff --git a/cui/source/customize/CustomNotebookbarGenerator.cxx b/cui/source/customize/CustomNotebookbarGenerator.cxx index c601d051ea11..9fb71562160a 100644 --- a/cui/source/customize/CustomNotebookbarGenerator.cxx +++ b/cui/source/customize/CustomNotebookbarGenerator.cxx @@ -29,6 +29,7 @@ #include <com/sun/star/frame/ModuleManager.hpp> #include <unotools/confignode.hxx> #include <libxml/parser.h> +#include <o3tl/string_view.hxx> #define aUIPropertiesCount 3 @@ -187,7 +188,7 @@ void CustomNotebookbarGenerator::modifyCustomizedUIFile(const Sequence<OUString> for (sal_Int32 aIndex = 0; aIndex < aUIPropertiesCount; aIndex++) { sal_Int32 nPos = aIndex; - OUString sToken = aValue.getToken(nPos, ',', nPos); + std::u16string_view sToken = o3tl::getToken(aValue, nPos, ',', nPos); aProperties[aIndex] = OUStringToOString(sToken, RTL_TEXTENCODING_UTF8); } xmlDocPtr doc = notebookbarXMLParser(sCustomizedUIPath, aProperties[0], aProperties[1], diff --git a/cui/source/customize/SvxNotebookbarConfigPage.cxx b/cui/source/customize/SvxNotebookbarConfigPage.cxx index 9c80960c669e..99c15b8f3ca9 100644 --- a/cui/source/customize/SvxNotebookbarConfigPage.cxx +++ b/cui/source/customize/SvxNotebookbarConfigPage.cxx @@ -482,7 +482,7 @@ static void EditRegistryFile(std::u16string_view sUIItemId, const OUString& sSet for (int nIdx = 0; nIdx < aOldEntries.getLength(); nIdx++) { sal_Int32 rPos = 0; - OUString sFirstValue = aOldEntries[nIdx].getToken(rPos, ',', rPos); + std::u16string_view sFirstValue = o3tl::getToken(aOldEntries[nIdx], rPos, ',', rPos); if (sFirstValue == sUIItemId) { aOldEntries.getArray()[nIdx] = sSetEntry; |