[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - linguistic/source
Eike Rathke
erack at redhat.com
Wed Aug 31 08:34:44 UTC 2016
linguistic/source/lngsvcmgr.cxx | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
New commits:
commit f6c109dc0d5ceee29143de038b230732f78e8ee6
Author: Eike Rathke <erack at redhat.com>
Date: Tue Aug 30 20:23:02 2016 +0200
Resolves: tdf#83376 do not let linguistic tools fall back to known languages
Falling back to known locales was necessary before the new language tag
implementation that can register "unknown" tags on the fly. In fact here we
want to handle tags unknown to us and not fall back to worst case en-US even,
so that dictionaries, grammar checkers, thesauri et al for any language tag can
be used with such tagged document content.
Change-Id: I06e54f41e00e69779b4c0cbbc891f250545a17d2
(cherry picked from commit 04311182b6fadcbdeef7aec15c7eea0240ee628c)
Reviewed-on: https://gerrit.libreoffice.org/28504
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
Tested-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/linguistic/source/lngsvcmgr.cxx b/linguistic/source/lngsvcmgr.cxx
index 3f5dbff..f1f78f4 100644
--- a/linguistic/source/lngsvcmgr.cxx
+++ b/linguistic/source/lngsvcmgr.cxx
@@ -839,7 +839,7 @@ void LngSvcMgr::Notify( const uno::Sequence< OUString > &rPropertyNames )
LanguageType nLang = LANGUAGE_NONE;
if (!aKeyText.isEmpty())
- nLang = LanguageTag::convertToLanguageTypeWithFallback( aKeyText );
+ nLang = LanguageTag::convertToLanguageType( aKeyText );
GetSpellCheckerDsp_Impl( false ); // don't set service list, it will be done below
pSpellDsp->SetServiceList( LanguageTag::convertToLocale(nLang), aSvcImplNames );
@@ -862,7 +862,7 @@ void LngSvcMgr::Notify( const uno::Sequence< OUString > &rPropertyNames )
LanguageType nLang = LANGUAGE_NONE;
if (!aKeyText.isEmpty())
- nLang = LanguageTag::convertToLanguageTypeWithFallback( aKeyText );
+ nLang = LanguageTag::convertToLanguageType( aKeyText );
if (SvtLinguConfig().HasGrammarChecker())
{
@@ -888,7 +888,7 @@ void LngSvcMgr::Notify( const uno::Sequence< OUString > &rPropertyNames )
LanguageType nLang = LANGUAGE_NONE;
if (!aKeyText.isEmpty())
- nLang = LanguageTag::convertToLanguageTypeWithFallback( aKeyText );
+ nLang = LanguageTag::convertToLanguageType( aKeyText );
GetHyphenatorDsp_Impl( false ); // don't set service list, it will be done below
pHyphDsp->SetServiceList( LanguageTag::convertToLocale(nLang), aSvcImplNames );
@@ -911,7 +911,7 @@ void LngSvcMgr::Notify( const uno::Sequence< OUString > &rPropertyNames )
LanguageType nLang = LANGUAGE_NONE;
if (!aKeyText.isEmpty())
- nLang = LanguageTag::convertToLanguageTypeWithFallback( aKeyText );
+ nLang = LanguageTag::convertToLanguageType( aKeyText );
GetThesaurusDsp_Impl( false ); // don't set service list, it will be done below
pThesDsp->SetServiceList( LanguageTag::convertToLocale(nLang), aSvcImplNames );
More information about the Libreoffice-commits
mailing list