diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-11-22 14:08:27 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-11-23 14:00:08 +0100 |
commit | ec1c4c49301758c54394f9943252e192ad54638b (patch) | |
tree | b53af3cb9154a388495b1af35c3f8ff41d6ebe1f /vcl/source/window/mnemonic.cxx | |
parent | db0f2c29bf3a6ad5a08f8524ea0e65aa90792bb2 (diff) |
O[U]String::replaceAt overloads that take string_view
which results in lots of nice string_view improvements picked up by the
plugins
Change-Id: Ib0ec3887816b3d4436d003b739d9814f83e244b2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125657
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'vcl/source/window/mnemonic.cxx')
-rw-r--r-- | vcl/source/window/mnemonic.cxx | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/vcl/source/window/mnemonic.cxx b/vcl/source/window/mnemonic.cxx index 4dd12668b48d..d412b2ad4071 100644 --- a/vcl/source/window/mnemonic.cxx +++ b/vcl/source/window/mnemonic.cxx @@ -195,7 +195,7 @@ OUString MnemonicGenerator::CreateMnemonic( const OUString& _rKey ) if ( maMnemonics[nMnemonicIndex] ) { maMnemonics[nMnemonicIndex] = 0; - rKey = rKey.replaceAt( nIndex, 0, OUString(m_cMnemonic) ); + rKey = rKey.replaceAt( nIndex, 0, rtl::OUStringChar(m_cMnemonic) ); bChanged = true; break; } @@ -247,7 +247,7 @@ OUString MnemonicGenerator::CreateMnemonic( const OUString& _rKey ) if ( nBestCount != 0xFFFF ) { maMnemonics[nBestMnemonicIndex] = 0; - rKey = rKey.replaceAt( nBestIndex, 0, OUString(m_cMnemonic) ); + rKey = rKey.replaceAt( nBestIndex, 0, rtl::OUStringChar(m_cMnemonic) ); bChanged = true; } } @@ -327,7 +327,7 @@ OUString MnemonicGenerator::EraseAllMnemonicChars( const OUString& rStr ) aStr[ i+2 ] == ')' && c >= MNEMONIC_RANGE_2_START && c <= MNEMONIC_RANGE_2_END ) { - aStr = aStr.replaceAt( i-1, 4, "" ); + aStr = aStr.replaceAt( i-1, 4, u"" ); nLen -= 4; i--; continue; @@ -335,7 +335,7 @@ OUString MnemonicGenerator::EraseAllMnemonicChars( const OUString& rStr ) } // remove standard mnemonics - aStr = aStr.replaceAt( i, 1, "" ); + aStr = aStr.replaceAt( i, 1, u"" ); nLen--; } else |