diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2006-02-23 10:55:31 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2006-02-23 10:55:31 +0000 |
commit | 4ce4095ffa480d6b68f38035bce2efa86905d1aa (patch) | |
tree | d6f428d1814ab90ca33a0620c3bd4878692a37ff /perl-install/lang.pm | |
parent | f84c186da0cd078b3ab842e6f38c5b31d28e415e (diff) | |
download | drakx-4ce4095ffa480d6b68f38035bce2efa86905d1aa.tar drakx-4ce4095ffa480d6b68f38035bce2efa86905d1aa.tar.gz drakx-4ce4095ffa480d6b68f38035bce2efa86905d1aa.tar.bz2 drakx-4ce4095ffa480d6b68f38035bce2efa86905d1aa.tar.xz drakx-4ce4095ffa480d6b68f38035bce2efa86905d1aa.zip |
create lang::lang_changed() to ensure {country} is set according to the lang (useful for finish-install where choosing fr gives fr_US)
Diffstat (limited to 'perl-install/lang.pm')
-rw-r--r-- | perl-install/lang.pm | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/perl-install/lang.pm b/perl-install/lang.pm index d692b3eca..64d07fcd7 100644 --- a/perl-install/lang.pm +++ b/perl-install/lang.pm @@ -983,6 +983,14 @@ sub system_locales_to_ourlocale { $locale; } +sub lang_changed { + my ($locale) = @_; + my $h = analyse_locale_name(l2locale($locale->{lang})); + $locale->{country} = $h->{country} if $h->{country}; + + $locale->{IM} = get_default_im($locale->{lang}); +} + sub read { my ($b_user_only) = @_; my ($f1, $f2) = ("$::prefix$ENV{HOME}/.i18n", "$::prefix/etc/sysconfig/i18n"); |