summaryrefslogtreecommitdiff
path: root/editeng
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2018-11-16 14:05:25 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-11-16 14:31:38 +0100
commit890afecb45bfcd2e53599974fbcf61fffd8f8a7b (patch)
tree9233bafbcfae88e93d387e501e3195aa3e98d2f4 /editeng
parentfaa63cd14c1d360d0e4eedb64cd879aa1229fa60 (diff)
loplugin:buriedassign in dbaccess..oox
Change-Id: Ic0ca695a1d9d05418213475a68e233953136cc8e Reviewed-on: https://gerrit.libreoffice.org/63468 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'editeng')
-rw-r--r--editeng/source/misc/svxacorr.cxx17
1 files changed, 10 insertions, 7 deletions
diff --git a/editeng/source/misc/svxacorr.cxx b/editeng/source/misc/svxacorr.cxx
index f84fba00dfff..f5f1c9077853 100644
--- a/editeng/source/misc/svxacorr.cxx
+++ b/editeng/source/misc/svxacorr.cxx
@@ -1252,12 +1252,15 @@ void SvxAutoCorrect::DoAutoCorrect( SvxAutoCorrDoc& rDoc, const OUString& rTxt,
if( bIsReplaceQuote )
{
sal_Unicode cPrev;
- bool bSttQuote = !nInsPos ||
- NonFieldWordDelim( ( cPrev = rTxt[ nInsPos-1 ])) ||
+ bool bSttQuote = !nInsPos;
+ if (!bSttQuote)
+ {
+ cPrev = rTxt[ nInsPos-1 ];
+ bSttQuote = NonFieldWordDelim(cPrev) ||
lcl_IsInAsciiArr( "([{", cPrev ) ||
( cEmDash == cPrev ) ||
( cEnDash == cPrev );
-
+ }
InsertQuote( rDoc, nInsPos, cChar, bSttQuote, bInsert );
break;
}
@@ -1890,15 +1893,15 @@ OUString SvxAutoCorrect::GetAutoCorrFileName( const LanguageTag& rLanguageTag,
sExt = "_" + sExt + ".dat";
if( bNewFile )
- ( sRet = sUserAutoCorrFile ) += sExt;
+ sRet = sUserAutoCorrFile + sExt;
else if( !bTst )
- ( sRet = sShareAutoCorrFile ) += sExt;
+ sRet = sShareAutoCorrFile + sExt;
else
{
// test first in the user directory - if not exist, then
- ( sRet = sUserAutoCorrFile ) += sExt;
+ sRet = sUserAutoCorrFile + sExt;
if( !FStatHelper::IsDocument( sRet ))
- ( sRet = sShareAutoCorrFile ) += sExt;
+ sRet = sShareAutoCorrFile + sExt;
}
return sRet;
}