--- pyanaconda/localization.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/pyanaconda/localization.py b/pyanaconda/localization.py index 47f4e01..d7c332c 100644 --- a/pyanaconda/localization.py +++ b/pyanaconda/localization.py @@ -154,8 +154,8 @@ def get_available_translations(domain=None, localedir=None): domain = domain or gettext._current_domain localedir = localedir or gettext._default_localedir
- langdict = babel.Locale('en', 'US').languages - messagefiles = gettext.find(domain, localedir, langdict.keys(), all=True) + langdict = babel.localedata.list() + messagefiles = gettext.find(domain, localedir, langdict, all=True) languages = [path.split(os.path.sep)[-3] for path in messagefiles]
# usually there are no message files for en
On Wed, 2012-10-24 at 15:45 -0400, Chris Lumens wrote:
pyanaconda/localization.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/pyanaconda/localization.py b/pyanaconda/localization.py index 47f4e01..d7c332c 100644 --- a/pyanaconda/localization.py +++ b/pyanaconda/localization.py @@ -154,8 +154,8 @@ def get_available_translations(domain=None, localedir=None): domain = domain or gettext._current_domain localedir = localedir or gettext._default_localedir
- langdict = babel.Locale('en', 'US').languages
- messagefiles = gettext.find(domain, localedir, langdict.keys(), all=True)
- langdict = babel.localedata.list()
- messagefiles = gettext.find(domain, localedir, langdict, all=True) languages = [path.split(os.path.sep)[-3] for path in messagefiles]
NACK.
In [13]: len(babel.Locale('en', 'US').languages.keys()) Out[13]: 506
In [14]: len(babel.localedata.list()) Out[14]: 451
I'm not sure we want something like that. Also langdict is not a good name for a variable containing a list.
NACK.
In [13]: len(babel.Locale('en', 'US').languages.keys()) Out[13]: 506
In [14]: len(babel.localedata.list()) Out[14]: 451
I don't think it's the number of results that matters so much as the quality of the results. Which is providing us with the results we care about? The first way's definitely not including a supported translation.
I'm not sure we want something like that. Also langdict is not a good name for a variable containing a list.
I can certainly rename it.
- Chris
anaconda-patches@lists.fedorahosted.org