summaryrefslogtreecommitdiff
path: root/editeng
diff options
context:
space:
mode:
authorNoel Grandin <noelgrandin@gmail.com>2017-05-28 19:41:52 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-08-17 11:55:13 +0200
commit9881bea8d41997fb46579eb5f0314300159c96cc (patch)
treef52daa7055d2d28959e2d1ad576d963b7c0d3b2d /editeng
parentec4034c4a4f23574401ba2a74b635d9ed4befbc8 (diff)
remove unnecessary use of OUString::getStr
Change-Id: I3d13e1c0bb6aa4a7aacc463198747c1368ebc9b4 Reviewed-on: https://gerrit.libreoffice.org/38114 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'editeng')
-rw-r--r--editeng/source/accessibility/AccessibleEditableTextPara.cxx2
-rw-r--r--editeng/source/editeng/impedit2.cxx10
2 files changed, 3 insertions, 9 deletions
diff --git a/editeng/source/accessibility/AccessibleEditableTextPara.cxx b/editeng/source/accessibility/AccessibleEditableTextPara.cxx
index bedc5da073ce..073547645c08 100644
--- a/editeng/source/accessibility/AccessibleEditableTextPara.cxx
+++ b/editeng/source/accessibility/AccessibleEditableTextPara.cxx
@@ -2068,7 +2068,7 @@ namespace accessibility
if( nIndex <= aBoundary.endPos )
{
nextWord = aBoundary.endPos;
- if( sText.getStr()[nextWord] == u' ' ) nextWord++;
+ if( sText[nextWord] == u' ' ) nextWord++;
bWord = implGetWordBoundary( aBoundary, nextWord );
}
diff --git a/editeng/source/editeng/impedit2.cxx b/editeng/source/editeng/impedit2.cxx
index 992913c03525..eaec3beb77bd 100644
--- a/editeng/source/editeng/impedit2.cxx
+++ b/editeng/source/editeng/impedit2.cxx
@@ -959,13 +959,11 @@ EditPaM ImpEditEngine::CursorVisualStartEnd( EditView const * pEditView, const E
{
OUString aLine = aPaM.GetNode()->GetString().copy(rLine.GetStart(), rLine.GetEnd() - rLine.GetStart());
- const sal_Unicode* pLineString = aLine.getStr();
-
UErrorCode nError = U_ZERO_ERROR;
UBiDi* pBidi = ubidi_openSized( aLine.getLength(), 0, &nError );
const UBiDiLevel nBidiLevel = IsRightToLeft( nPara ) ? 1 /*RTL*/ : 0 /*LTR*/;
- ubidi_setPara( pBidi, reinterpret_cast<const UChar *>(pLineString), aLine.getLength(), nBidiLevel, nullptr, &nError );
+ ubidi_setPara( pBidi, reinterpret_cast<const UChar *>(aLine.getStr()), aLine.getLength(), nBidiLevel, nullptr, &nError );
sal_Int32 nVisPos = bStart ? 0 : aLine.getLength()-1;
const sal_Int32 nLogPos = ubidi_getLogicalIndex( pBidi, nVisPos, &nError );
@@ -1080,13 +1078,11 @@ EditPaM ImpEditEngine::CursorVisualLeftRight( EditView const * pEditView, const
OUString aLine = aPaM.GetNode()->GetString().copy(rLine.GetStart(), rLine.GetEnd() - rLine.GetStart());
const sal_Int32 nPosInLine = aPaM.GetIndex() - rLine.GetStart();
- const sal_Unicode* pLineString = aLine.getStr();
-
UErrorCode nError = U_ZERO_ERROR;
UBiDi* pBidi = ubidi_openSized( aLine.getLength(), 0, &nError );
const UBiDiLevel nBidiLevel = IsRightToLeft( nPara ) ? 1 /*RTL*/ : 0 /*LTR*/;
- ubidi_setPara( pBidi, reinterpret_cast<const UChar *>(pLineString), aLine.getLength(), nBidiLevel, nullptr, &nError );
+ ubidi_setPara( pBidi, reinterpret_cast<const UChar *>(aLine.getStr()), aLine.getLength(), nBidiLevel, nullptr, &nError );
if ( !pEditView->IsInsertMode() )
{
@@ -1931,10 +1927,8 @@ void ImpEditEngine::InitWritingDirections( sal_Int32 nPara )
const UBiDiLevel nBidiLevel = IsRightToLeft( nPara ) ? 1 /*RTL*/ : 0 /*LTR*/;
if ( ( bCTL || ( nBidiLevel == 1 /*RTL*/ ) ) && pParaPortion->GetNode()->Len() )
{
-
OUString aText = pParaPortion->GetNode()->GetString();
-
// Bidi functions from icu 2.0
UErrorCode nError = U_ZERO_ERROR;