diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2000-08-06 00:38:57 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2000-08-06 00:38:57 +0000 |
commit | c75193289b79d4c0687aa6a597b51436568f8360 (patch) | |
tree | 0dde0958b1d48a729e30be420f9f8c94004b7ef8 /perl-install/any.pm | |
parent | c5d30320d3d120ccd291ccc7b7271400a4f20e4a (diff) | |
download | drakx-c75193289b79d4c0687aa6a597b51436568f8360.tar drakx-c75193289b79d4c0687aa6a597b51436568f8360.tar.gz drakx-c75193289b79d4c0687aa6a597b51436568f8360.tar.bz2 drakx-c75193289b79d4c0687aa6a597b51436568f8360.tar.xz drakx-c75193289b79d4c0687aa6a597b51436568f8360.zip |
no_comment
Diffstat (limited to 'perl-install/any.pm')
-rw-r--r-- | perl-install/any.pm | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/perl-install/any.pm b/perl-install/any.pm index 7f59db74a..7e50c1dbc 100644 --- a/perl-install/any.pm +++ b/perl-install/any.pm @@ -122,11 +122,17 @@ _("Restrict command line options") => { val => \$b->{restricted}, type => "bool" until ($::beginner && $more <= 1) { $in->set_help(arch() =~ /sparc/ ? 'setupSILOAddEntry' : 'setupBootloaderAddEntry') unless $::isStandalone; - my $c = $in->ask_from_list_([''], + my $c = $in->ask_from_listf([''], _("Here are the different entries. You can add some more or change the existing ones."), - [ (sort @{[map { "$_->{label} ($_->{kernel_or_dev})" . ($b->{default} eq $_->{label} && " *") } @{$b->{entries}}]}), __("Add"), __("Done") ], - ); + sub { + my ($e) = @_; + ref $e ? + "$e->{label} ($e->{kernel_or_dev})" . ($b->{default} eq $e->{label} && " *") : + translate($e); + }, + [ @{$b->{entries}}, __("Add"), __("Done") ]); + $c eq "Done" and last; my ($e); @@ -147,9 +153,8 @@ You can add some more or change the existing ones."), } $e->{label} = $prefix; for (my $nb = 0; member($e->{label}, @labels); $nb++) { $e->{label} = "$prefix-$nb" } - } else { - $c =~ /(.*) \(/; - ($e) = grep { $_->{label} eq $1 } @{$b->{entries}}; + } else { + $e = $c; } my %old_e = %$e; my $default = my $old_default = $e->{label} eq $b->{default}; |