diff options
author | Eike Rathke <erack@redhat.com> | 2022-06-07 15:36:03 +0200 |
---|---|---|
committer | Andras Timar <andras.timar@collabora.com> | 2022-06-09 11:02:06 +0200 |
commit | 9c9a9fed4558ca4b11d2d3615c94eedecee2efaa (patch) | |
tree | 33b5a642d82e387898d40906261f8908a4ba1cc2 /i18nlangtag | |
parent | fb4b7c63bda11451dd883618c58628d1050c17fb (diff) |
Related: tdf#147390 Accept oc-FR-lengadoc and oc-ES-aranes for oc-FR and oc-ES
... as aliases for forward compatibility with the change in LO 7.4
Change-Id: I13848f982a0c76abd8e2186d81bbfc9770c89a7d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135473
Tested-by: Jenkins
Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
Diffstat (limited to 'i18nlangtag')
-rw-r--r-- | i18nlangtag/qa/cppunit/test_languagetag.cxx | 2 | ||||
-rw-r--r-- | i18nlangtag/source/isolang/isolang.cxx | 2 |
2 files changed, 4 insertions, 0 deletions
diff --git a/i18nlangtag/qa/cppunit/test_languagetag.cxx b/i18nlangtag/qa/cppunit/test_languagetag.cxx index 84e363d01eb4..7b875c5832d5 100644 --- a/i18nlangtag/qa/cppunit/test_languagetag.cxx +++ b/i18nlangtag/qa/cppunit/test_languagetag.cxx @@ -749,6 +749,8 @@ bool checkMapping( std::u16string_view rStr1, std::u16string_view rStr2 ) if (rStr1 == u"cmn-CN" ) return rStr2 == u"zh-CN"; if (rStr1 == u"cmn-TW" ) return rStr2 == u"zh-TW"; if (rStr1 == u"kw-UK" ) return rStr2 == u"kw-GB"; + if (rStr1 == u"oc-FR-lengadoc" ) return rStr2 == u"oc-FR"; + if (rStr1 == u"oc-ES-aranes" ) return rStr2 == u"oc-ES"; return rStr1 == rStr2; } diff --git a/i18nlangtag/source/isolang/isolang.cxx b/i18nlangtag/source/isolang/isolang.cxx index 5d0a23c1f6d7..2a7a46763886 100644 --- a/i18nlangtag/source/isolang/isolang.cxx +++ b/i18nlangtag/source/isolang/isolang.cxx @@ -778,6 +778,8 @@ Bcp47CountryEntry const aImplBcp47CountryEntries[] = { LANGUAGE_USER_ENGLISH_UK_OED, "en-GB-oed", "GB", "", LANGUAGE_USER_ENGLISH_UK_OXENDICT }, // grandfathered, deprecated, prefer en-GB-oxendict { LANGUAGE_SPANISH_DATED, "es-ES-u-co-trad", "ES", "es-u-co-trad", k0 }, // RFC6067/CLDR { LANGUAGE_SPANISH_DATED, "es-ES_tradnl", "ES", "", kSAME }, // MS malformed + { LANGUAGE_OCCITAN_FRANCE, "oc-FR-lengadoc", "FR", "oc-lengadoc", kSAME }, // forward compatibility + { LANGUAGE_USER_OCCITAN_ARANESE, "oc-ES-aranes", "ES", "oc-aranes", kSAME }, // forward compatibility // { LANGUAGE_YUE_CHINESE_HONGKONG, "zh-yue-HK", "HK", "", 0 }, // MS reserved, prefer yue-HK; do not add unless LanguageTag::simpleExtract() can handle it to not call liblangtag for rsc! { LANGUAGE_YIDDISH, "yi-001", "", "", k0 }, // MS since rev.15, was "yi-Hebr" reserved, "001"="World" { LANGUAGE_FRENCH_WEST_INDIES, "fr-029", "", "", k0 }, // MS since rev.15, was "Neither defined nor reserved", "029"="Caribbean" |