diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2002-12-29 13:19:29 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2002-12-29 13:19:29 +0000 |
commit | 5a0dfe7fa86b8d86f7a035f79f8072bd6ad0a7d6 (patch) | |
tree | 3e79d8e3c3ff338ecee0338a127f3a5e3354b904 /perl-install | |
parent | 52398befc67df4860b0ba91e66875ac7992bdccc (diff) | |
download | drakx-backup-do-not-use-5a0dfe7fa86b8d86f7a035f79f8072bd6ad0a7d6.tar drakx-backup-do-not-use-5a0dfe7fa86b8d86f7a035f79f8072bd6ad0a7d6.tar.gz drakx-backup-do-not-use-5a0dfe7fa86b8d86f7a035f79f8072bd6ad0a7d6.tar.bz2 drakx-backup-do-not-use-5a0dfe7fa86b8d86f7a035f79f8072bd6ad0a7d6.tar.xz drakx-backup-do-not-use-5a0dfe7fa86b8d86f7a035f79f8072bd6ad0a7d6.zip |
cleanup (using ask_from instead of ask_from_listf_)
Diffstat (limited to 'perl-install')
-rw-r--r-- | perl-install/any.pm | 18 |
1 files changed, 8 insertions, 10 deletions
diff --git a/perl-install/any.pm b/perl-install/any.pm index a7a57b5a0..d8b0804b9 100644 --- a/perl-install/any.pm +++ b/perl-install/any.pm @@ -108,11 +108,9 @@ sub setupBootloader { $in->set_help('setupBootloaderBeginner') unless $::isStandalone; if (arch() =~ /sparc/) { - $b->{use_partition} = $in->ask_from_listf_(N("SILO Installation"), - N("Where do you want to install the bootloader?"), - sub { $l[$_[0]] }, - [ 0, 1 ], $b->{use_partition}); - defined $b->{use_partition} or return 0 + $in->ask_from(N("SILO Installation"), + N("Where do you want to install the bootloader?"), + { val => \$b->{use_partition}, list => [ 0, 1 ], format => sub { translate($l[$_[0]]) } }) or return 0; } elsif (arch() =~ /ppc/) { if (defined $partition_table::mac::bootstrap_part) { $b->{boot} = $partition_table::mac::bootstrap_part; @@ -122,11 +120,11 @@ sub setupBootloader { } } else { my $boot = $hds->[0]{device}; - my $onmbr = "/dev/$boot" eq $b->{boot}; - $b->{boot} = "/dev/" . ($in->ask_from_list_(N("LILO/grub Installation"), - N("Where do you want to install the bootloader?"), - \@l, $l[!$onmbr]) eq $l[0] ? - $boot : fsedit::get_root($fstab, 'boot')->{device}); + my $use_partition = "/dev/$boot" ne $b->{boot}; + $in->ask_from(N("LILO/grub Installation"), + N("Where do you want to install the bootloader?"), + { val => \$use_partition, list => [ 0, 1 ], format => sub { translate($l[$_[0]]) } }); + $b->{boot} = "/dev/" . ($use_partition ? fsedit::get_root($fstab, 'boot')->{device} : $boot); } } else { $in->set_help(arch() =~ /sparc/ ? "setupSILOGeneral" : arch() =~ /ppc/ ? 'setupYabootGeneral' : "setupBootloader") unless $::isStandalone; #- TO MERGE ? |