summaryrefslogtreecommitdiffstats
path: root/perl-install/any.pm
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2001-08-29 17:31:16 +0000
committerPascal Rigaux <pixel@mandriva.com>2001-08-29 17:31:16 +0000
commit909cfffcd84cb05d8b4c5ab5057bbdcfb230fee7 (patch)
treea663c431f0076f3c03c555663ea8a5f326b367fe /perl-install/any.pm
parent17675cf6acfe4d3b9e092284484371dc3bdcc7e1 (diff)
downloaddrakx-backup-do-not-use-909cfffcd84cb05d8b4c5ab5057bbdcfb230fee7.tar
drakx-backup-do-not-use-909cfffcd84cb05d8b4c5ab5057bbdcfb230fee7.tar.gz
drakx-backup-do-not-use-909cfffcd84cb05d8b4c5ab5057bbdcfb230fee7.tar.bz2
drakx-backup-do-not-use-909cfffcd84cb05d8b4c5ab5057bbdcfb230fee7.tar.xz
drakx-backup-do-not-use-909cfffcd84cb05d8b4c5ab5057bbdcfb230fee7.zip
add localedrake (not tested)
Diffstat (limited to 'perl-install/any.pm')
-rw-r--r--perl-install/any.pm21
1 files changed, 21 insertions, 0 deletions
diff --git a/perl-install/any.pm b/perl-install/any.pm
index 2696017d2..4889dff70 100644
--- a/perl-install/any.pm
+++ b/perl-install/any.pm
@@ -12,6 +12,7 @@ use detect_devices;
use partition_table qw(:types);
use fsedit;
use fs;
+use lang;
use run_program;
use modules;
use log;
@@ -769,6 +770,26 @@ Do you want to use this feature?'),
}
}
+sub selectLanguage {
+ my ($in, $lang, $langs) = @_;
+ $in->ask_from_(
+ { messages => _("Please, choose a language to use."),
+ advanced_messages => _("You can choose other languages that will be available after install"),
+ callbacks => {
+ focus_out => sub { $langs->{$lang} = 1 },
+ },
+ },
+ [ { val => \$lang, separator => '|',
+ format => \&lang::lang2text, list => [ lang::list() ] },
+ (map {;
+ { val => \$langs->{$_->[0]}, type => 'bool', disabled => sub { $langs->{all} },
+ text => $_->[1], advanced => 1,
+ }
+ } sort { $a->[1] cmp $b->[1] } map { [ $_, lang::lang2text($_) ] } lang::list()),
+ { val => \$langs->{all}, type => 'bool', text => _("All"), advanced => 1 }
+ ]) and $lang;
+}
+
sub write_passwd_user {
my ($prefix, $u, $isMD5) = @_;