mirror of
https://gitee.com/openharmony/global_i18n
synced 2024-11-23 07:00:13 +00:00
Merge pull request !842 from zhangdd_ewan/revert-merge-832-master
This commit is contained in:
commit
67b1f53150
@ -150,6 +150,7 @@ ohos_shared_library("intl_util") {
|
||||
":zh_Hans_lang_xml",
|
||||
":zh_Hans_region_xml",
|
||||
":zh_Hans_timezone_xml",
|
||||
":zh_Hant_HK_lang_xml",
|
||||
":zh_Hant_lang_xml",
|
||||
":zh_datetime_xml",
|
||||
]
|
||||
@ -292,6 +293,13 @@ ohos_prebuilt_etc("zh_Hant_lang_xml") {
|
||||
subsystem_name = "global"
|
||||
}
|
||||
|
||||
ohos_prebuilt_etc("zh_Hant_HK_lang_xml") {
|
||||
source = "//base/global/i18n/frameworks/intl/etc/lang/zh-Hant-HK.xml"
|
||||
module_install_dir = "etc/ohos_lang_config/"
|
||||
part_name = "i18n"
|
||||
subsystem_name = "global"
|
||||
}
|
||||
|
||||
ohos_prebuilt_etc("bo_lang_xml") {
|
||||
source = "//base/global/i18n/frameworks/intl/etc/lang/bo.xml"
|
||||
module_install_dir = "etc/ohos_lang_config/"
|
||||
|
@ -25,6 +25,10 @@
|
||||
<id>zh-Hant</id>
|
||||
<display_name>བརྡ་རྙིང་རྒྱ་ཡིག</display_name>
|
||||
</lang>
|
||||
<lang>
|
||||
<id>zh-Hant-HK</id>
|
||||
<display_name>བརྡ་རྙིང་རྒྱ་ཡིག(ཀྲུང་གོའི་ཞང་ཀང་།)</display_name>
|
||||
</lang>
|
||||
<lang>
|
||||
<id>ro</id>
|
||||
<display_name>རོ་མ་ནི་ཡའི་སྐད།</display_name>
|
||||
|
@ -25,6 +25,10 @@
|
||||
<id>zh-Hant</id>
|
||||
<display_name>Traditional Chinese</display_name>
|
||||
</lang>
|
||||
<lang>
|
||||
<id>zh-Hant-HK</id>
|
||||
<display_name>Traditional Chinese(Hong Kong, China)</display_name>
|
||||
</lang>
|
||||
<lang>
|
||||
<id>ro</id>
|
||||
<display_name>Romanian</display_name>
|
||||
|
@ -16,6 +16,7 @@
|
||||
<item>en-Latn</item>
|
||||
<item>zh-Hans</item>
|
||||
<item>zh-Hant</item>
|
||||
<item>zh-Hant-HK</item>
|
||||
<item>bo</item>
|
||||
<item>ug</item>
|
||||
</supported_locales>
|
@ -17,6 +17,10 @@
|
||||
<id>zh-Hant</id>
|
||||
<display_name>ئەنئەنىۋىي خەنزۇچە</display_name>
|
||||
</lang>
|
||||
<lang>
|
||||
<id>zh-Hant-HK</id>
|
||||
<display_name>ئەنئەنىۋىي خەنزۇچە (جۇڭگو شياڭگاڭ)</display_name>
|
||||
</lang>
|
||||
<lang>
|
||||
<id>ro</id>
|
||||
<display_name>رومىنچە</display_name>
|
||||
|
@ -25,6 +25,10 @@
|
||||
<id>zh-Hant</id>
|
||||
<display_name>繁体中文</display_name>
|
||||
</lang>
|
||||
<lang>
|
||||
<id>zh-Hant-HK</id>
|
||||
<display_name>繁体中文(中国香港)</display_name>
|
||||
</lang>
|
||||
<lang>
|
||||
<id>ro</id>
|
||||
<display_name>罗马尼亚文</display_name>
|
||||
|
40
frameworks/intl/etc/lang/zh-Hant-HK.xml
Normal file
40
frameworks/intl/etc/lang/zh-Hant-HK.xml
Normal file
@ -0,0 +1,40 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!-- Copyright (c) 2022 Huawei Device Co., Ltd.
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
-->
|
||||
<languages>
|
||||
<lang>
|
||||
<id>zh</id>
|
||||
<display_name>中文</display_name>
|
||||
</lang>
|
||||
<lang>
|
||||
<id>zh-Hans</id>
|
||||
<display_name>簡體中文</display_name>
|
||||
</lang>
|
||||
<lang>
|
||||
<id>zh-Hant</id>
|
||||
<display_name>繁體中文</display_name>
|
||||
</lang>
|
||||
<lang>
|
||||
<id>zh-Hant-HK</id>
|
||||
<display_name>繁體中文(中國香港)</display_name>
|
||||
</lang>
|
||||
<lang>
|
||||
<id>ro</id>
|
||||
<display_name>羅馬尼亞文</display_name>
|
||||
</lang>
|
||||
<lang>
|
||||
<id>fa</id>
|
||||
<display_name>波斯文</display_name>
|
||||
</lang>
|
||||
</languages>
|
@ -25,6 +25,10 @@
|
||||
<id>zh-Hant</id>
|
||||
<display_name>繁體中文</display_name>
|
||||
</lang>
|
||||
<lang>
|
||||
<id>zh-Hant-HK</id>
|
||||
<display_name>繁體中文(中國香港)</display_name>
|
||||
</lang>
|
||||
<lang>
|
||||
<id>ro</id>
|
||||
<display_name>羅馬尼亞文</display_name>
|
||||
|
@ -15,14 +15,14 @@
|
||||
<regions>
|
||||
<region>
|
||||
<id>HK</id>
|
||||
<display_name>Hong Kong (China)</display_name>
|
||||
<display_name>Hong Kong, China</display_name>
|
||||
</region>
|
||||
<region>
|
||||
<id>MO</id>
|
||||
<display_name>Macao (China)</display_name>
|
||||
<display_name>Macao, China</display_name>
|
||||
</region>
|
||||
<region>
|
||||
<id>TW</id>
|
||||
<display_name>Taiwan (China)</display_name>
|
||||
<display_name>Taiwan, China</display_name>
|
||||
</region>
|
||||
</regions>
|
@ -251,7 +251,7 @@ HWTEST_F(LocaleConfigTest, LocaleConfigFuncTest009, TestSize.Level1)
|
||||
|
||||
regionTag = "HK";
|
||||
displayName = LocaleConfig::GetDisplayRegion(regionTag, localeTag, false);
|
||||
EXPECT_EQ(displayName, "Hong Kong (China)");
|
||||
EXPECT_EQ(displayName, "Hong Kong, China");
|
||||
}
|
||||
|
||||
/**
|
||||
@ -264,17 +264,17 @@ HWTEST_F(LocaleConfigTest, LocaleConfigFuncTest010, TestSize.Level1)
|
||||
std::string languageTag = "zh-Hant-HK";
|
||||
std::string localeTag = "zh-Hant";
|
||||
std::string displayName = LocaleConfig::GetDisplayLanguage(languageTag, localeTag, true);
|
||||
EXPECT_EQ(displayName, "繁體中文");
|
||||
EXPECT_EQ(displayName, "繁體中文(中國香港)");
|
||||
|
||||
languageTag = "zh-Hant-HK";
|
||||
localeTag = "zh-Hans";
|
||||
displayName = LocaleConfig::GetDisplayLanguage(languageTag, localeTag, true);
|
||||
EXPECT_EQ(displayName, "繁体中文");
|
||||
EXPECT_EQ(displayName, "繁体中文(中国香港)");
|
||||
|
||||
languageTag = "zh-Hant-HK";
|
||||
localeTag = "en-US";
|
||||
displayName = LocaleConfig::GetDisplayLanguage(languageTag, localeTag, true);
|
||||
EXPECT_EQ(displayName, "Traditional Chinese");
|
||||
EXPECT_EQ(displayName, "Traditional Chinese(Hong Kong, China)");
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user