diff options
author | Eike Rathke <erack@redhat.com> | 2013-09-21 15:20:49 +0200 |
---|---|---|
committer | Eike Rathke <erack@redhat.com> | 2013-09-21 15:30:00 +0200 |
commit | a641bbff59cdd55cfc9757e6a43e732a3c8867be (patch) | |
tree | a0e1c567b9205e50df28879e1fb963fe219b5103 /sw | |
parent | dafd27829359201cab45462bae43baf19b369a14 (diff) |
map autocorrection files with LanguageTag key
... as several tags (i.e. renamed) may map to the same LangID.
Change-Id: I8202b18ea0dc8034522017be59bb104b3d06c0f4
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/core/edit/acorrect.cxx | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sw/source/core/edit/acorrect.cxx b/sw/source/core/edit/acorrect.cxx index 4599e752b158..8d9fb7c951e2 100644 --- a/sw/source/core/edit/acorrect.cxx +++ b/sw/source/core/edit/acorrect.cxx @@ -312,13 +312,14 @@ bool SwAutoCorrDoc::ChgAutoCorrWord( sal_Int32& rSttPos, sal_Int32 nEndPos, LanguageType eLang = GetLanguage(nEndPos, sal_False); if(LANGUAGE_SYSTEM == eLang) eLang = GetAppLanguage(); + LanguageTag aLanguageTag( eLang); //JP 22.04.99: Bug 63883 - Special treatment for dots. bool bLastCharIsPoint = nEndPos < pTxtNd->GetTxt().getLength() && ('.' == pTxtNd->GetTxt()[nEndPos]); const SvxAutocorrWord* pFnd = rACorrect.SearchWordsInList( - pTxtNd->GetTxt(), rSttPos, nEndPos, *this, eLang ); + pTxtNd->GetTxt(), rSttPos, nEndPos, *this, aLanguageTag ); SwDoc* pDoc = rEditSh.GetDoc(); if( pFnd ) { @@ -338,7 +339,7 @@ bool SwAutoCorrDoc::ChgAutoCorrWord( sal_Int32& rSttPos, sal_Int32 nEndPos, } else { - SwTextBlocks aTBlks( rACorrect.GetAutoCorrFileName( eLang, sal_False, sal_True )); + SwTextBlocks aTBlks( rACorrect.GetAutoCorrFileName( aLanguageTag, sal_False, sal_True )); sal_uInt16 nPos = aTBlks.GetIndex( pFnd->GetShort() ); if( USHRT_MAX != nPos && aTBlks.BeginGetDoc( nPos ) ) { |