summaryrefslogtreecommitdiff
path: root/sw/source/core/edit/edlingu.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'sw/source/core/edit/edlingu.cxx')
-rw-r--r--sw/source/core/edit/edlingu.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/sw/source/core/edit/edlingu.cxx b/sw/source/core/edit/edlingu.cxx
index 185e17e14b7c..85c4283380aa 100644
--- a/sw/source/core/edit/edlingu.cxx
+++ b/sw/source/core/edit/edlingu.cxx
@@ -980,7 +980,7 @@ bool SwEditShell::GetGrammarCorrection(
// Expand the string:
const ModelToViewHelper aConversionMap(*pNode);
- OUString aExpandText = aConversionMap.getViewText();
+ const OUString& aExpandText = aConversionMap.getViewText();
// get XFlatParagraph to use...
uno::Reference< text::XFlatParagraph > xFlatPara = new SwXFlatParagraph( *pNode, aExpandText, aConversionMap );
@@ -1445,7 +1445,7 @@ bool SwSpellIter::SpellSentence(svx::SpellPortions& rPortions, bool bIsGrammarCh
if( bGrammarErrorFound )
{
const ModelToViewHelper aConversionMap(static_cast<SwTextNode&>(pCursor->GetNode()));
- OUString aExpandText = aConversionMap.getViewText();
+ const OUString& aExpandText = aConversionMap.getViewText();
sal_Int32 nSentenceEnd =
aConversionMap.ConvertToViewPosition( aGrammarResult.nBehindEndOfSentencePosition );
// remove trailing space