diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2021-11-26 08:19:33 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2021-11-26 09:45:34 +0100 |
commit | 6dfcabf54a86f7204b4924718a930be5d13b1eeb (patch) | |
tree | cedeca0f62426622b18d44cf64451ea20fe5c365 /winaccessibility | |
parent | 32842d4bf250bcab281eb71a218d618485c60290 (diff) |
loplugin:stringviewparam
Change-Id: I8a4c310e3a963362bff390e93ca39a7583e83e1e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125857
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'winaccessibility')
-rw-r--r-- | winaccessibility/source/UAccCOM/AccTextBase.cxx | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/winaccessibility/source/UAccCOM/AccTextBase.cxx b/winaccessibility/source/UAccCOM/AccTextBase.cxx index 47225cb46f25..a71431fc1d22 100644 --- a/winaccessibility/source/UAccCOM/AccTextBase.cxx +++ b/winaccessibility/source/UAccCOM/AccTextBase.cxx @@ -882,7 +882,7 @@ COM_DECLSPEC_NOTHROW STDMETHODIMP CAccTextBase::put_XInterface(hyper pXInterface LEAVE_PROTECTED_BLOCK } -static OUString ReplaceOneChar(OUString const & oldOUString, sal_Unicode replacedChar, OUString const & replaceStr) +static OUString ReplaceOneChar(OUString const & oldOUString, sal_Unicode replacedChar, std::u16string_view replaceStr) { auto s = oldOUString; int iReplace = s.lastIndexOf(replacedChar); @@ -900,11 +900,11 @@ static OUString ReplaceOneChar(OUString const & oldOUString, sal_Unicode replace static OUString ReplaceFourChar(OUString const & oldOUString) { auto s = oldOUString; - s = ReplaceOneChar(s, '\\', "\\\\"); - s = ReplaceOneChar(s, ';', "\\;"); - s = ReplaceOneChar(s, '=', "\\="); - s = ReplaceOneChar(s, ',', "\\,"); - s = ReplaceOneChar(s, ':', "\\:"); + s = ReplaceOneChar(s, '\\', u"\\\\"); + s = ReplaceOneChar(s, ';', u"\\;"); + s = ReplaceOneChar(s, '=', u"\\="); + s = ReplaceOneChar(s, ',', u"\\,"); + s = ReplaceOneChar(s, ':', u"\\:"); return s; } |