summaryrefslogtreecommitdiff
path: root/ibus
diff options
context:
space:
mode:
authorfujiwarat <takao.fujiwara1@gmail.com>2019-06-24 17:28:55 +0900
committerfujiwarat <takao.fujiwara1@gmail.com>2019-06-24 17:28:55 +0900
commit80254484071eb57e1152579b60ec8a95522ebc22 (patch)
treead0e3c53ffcdf511240773f1bddf262b304dec0e /ibus
parent82a728de97308f6ce36c814e30a292f96e76cc13 (diff)
downloadibus-80254484071eb57e1152579b60ec8a95522ebc22.tar.gz
src: s/iso_639-3/iso_639_3/ in ibus_get_language_name()
iso-codes 3.66 has iso_639_3.xml only but 3.67 has both iso_639_3.xml and iso_639-3.xml. RHEL 7 uses iso-codes 3.46. BUG=https://github.com/ibus/ibus/issues/2101
Diffstat (limited to 'ibus')
-rw-r--r--ibus/lang.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/ibus/lang.py b/ibus/lang.py
index 64324bd8..238a9172 100644
--- a/ibus/lang.py
+++ b/ibus/lang.py
@@ -3,7 +3,7 @@
# ibus - The Input Bus
#
# Copyright (c) 2007-2010 Peng Huang <shawn.p.huang@gmail.com>
-# Copyright (c) 2007-2010 Red Hat, Inc.
+# Copyright (c) 2007-2019 Red Hat, Inc.
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
@@ -36,7 +36,7 @@ def get_language_name(_locale):
lang = lang.lower()
if lang in __languages_dict:
lang = __languages_dict[lang]
- lang = gettext.dgettext("iso_639-3", lang)
+ lang = gettext.dgettext("iso_639_3", lang)
else:
lang = _(u"Other")
lang = gettext.dgettext("ibus", lang)
@@ -62,7 +62,7 @@ def __char_data(data):
def __load_lang():
import os
import _config
- iso_639_3_xml = os.path.join(_config.ISOCODES_PREFIX, "share/xml/iso-codes/iso_639-3.xml")
+ iso_639_3_xml = os.path.join(_config.ISOCODES_PREFIX, "share/xml/iso-codes/iso_639_3.xml")
p = xml.parsers.expat.ParserCreate()
p.StartElementHandler = __start_element
p.EndElementHandler = __end_element