diff options
author | Tor Lillqvist <tml@collabora.com> | 2021-03-18 13:45:18 +0200 |
---|---|---|
committer | Tor Lillqvist <tml@collabora.com> | 2021-03-19 06:31:54 +0100 |
commit | 370984c385dbc52c8ee7e6e71f4c0cc085fee422 (patch) | |
tree | 17a636e4993c7731e4c019ffec884e7a87d57dbb /lingucomponent | |
parent | 6e4238018bf0408f2961e5708212e09a8c3597dc (diff) |
Use the iOS fr_FR and it_IT dictionaries for other relevant countries, too
Fixes https://github.com/CollaboraOnline/online/issues/1463
Change-Id: I9fffd4bc9499aee2098258f5c3a9181330b339a1
Signed-off-by: Tor Lillqvist <tml@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112670
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112690
Diffstat (limited to 'lingucomponent')
-rw-r--r-- | lingucomponent/source/spellcheck/macosxspell/macspellimp.mm | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/lingucomponent/source/spellcheck/macosxspell/macspellimp.mm b/lingucomponent/source/spellcheck/macosxspell/macspellimp.mm index a919015f8ca5..874f14bc0f19 100644 --- a/lingucomponent/source/spellcheck/macosxspell/macspellimp.mm +++ b/lingucomponent/source/spellcheck/macosxspell/macspellimp.mm @@ -197,11 +197,36 @@ Sequence< Locale > SAL_CALL MacSpellChecker::getLocales() postspdict.push_back( pLangStr ); } } +#ifdef IOS + else if ([pLangStr isEqualToString:@"fr_FR"]) + { + const std::vector<NSString*> aFR + { @"BE", @"BF", @"BJ", @"CA", @"CH", @"CI", @"FR", @"LU", @"MC", @"ML", + @"MU", @"NE", @"SN", @"TG" }; + for (auto c: aFR) + { + pLangStr = [@"fr_" stringByAppendingString: c]; + postspdict.push_back( pLangStr ); + } + } +#endif else if ([pLangStr isEqualToString:@"it"]) { postspdict.push_back( @"it_CH" ); postspdict.push_back( @"it_IT" ); } +#ifdef IOS + else if ([pLangStr isEqualToString:@"it_IT"]) + { + const std::vector<NSString*> aIT + { @"CH", @"IT" }; + for (auto c: aIT) + { + pLangStr = [@"it_" stringByAppendingString: c]; + postspdict.push_back( pLangStr ); + } + } +#endif else if ([pLangStr isEqualToString:@"ko"]) { postspdict.push_back( @"ko_KR" ); |