summaryrefslogtreecommitdiffstats
path: root/perl-install/interactive.pm
diff options
context:
space:
mode:
Diffstat (limited to 'perl-install/interactive.pm')
-rw-r--r--perl-install/interactive.pm10
1 files changed, 7 insertions, 3 deletions
diff --git a/perl-install/interactive.pm b/perl-install/interactive.pm
index 928c00c91..1d4dd0c68 100644
--- a/perl-install/interactive.pm
+++ b/perl-install/interactive.pm
@@ -98,7 +98,12 @@ sub ask_yesorno {
sub ask_okcancel {
my ($o, $title, $message, $def, $help) = @_;
- ask_from_list_($o, $title, $message, [ __("Ok"), __("Cancel") ], $def ? "Ok" : "Cancel", $help) eq "Ok";
+
+ if ($::isWizard) {
+ $o->ask_from_entries_refH({ title => $title, messages => $message, focus_cancel => !$def });
+ } else {
+ ask_from_list_($o, $title, $message, [ __("Ok"), __("Cancel") ], $def ? "Ok" : "Cancel", $help) eq "Ok";
+ }
}
sub ask_from_list {
@@ -131,8 +136,7 @@ sub ask_from_listf_no_check {
if_($l->[1], cancel => may_apply($f, $l->[1]), focus_cancel => $def eq $l->[1]) }, []
) ? $l->[0] : $l->[1];
} else {
- ask_from_entries_refH($o, $title, $message, [ { val => \$def, type => 'list', list => $l, help => $help, format => $f } ]) or die 'ask_from_list cancel';
- $def;
+ ask_from_entries_refH($o, $title, $message, [ { val => \$def, type => 'list', list => $l, help => $help, format => $f } ]) && $def;
}
}