diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2008-10-21 16:18:20 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2008-10-21 16:18:20 +0000 |
commit | 01508b09ee68c55499c1b1a5ea658bb03204b96c (patch) | |
tree | 2c7bb480fad36a9cf020a42dcdeedf83552927ea /urpmi | |
parent | 4d4f0f02bdb78f485e0735e591b98204e6fe8d11 (diff) | |
download | urpmi-01508b09ee68c55499c1b1a5ea658bb03204b96c.tar urpmi-01508b09ee68c55499c1b1a5ea658bb03204b96c.tar.gz urpmi-01508b09ee68c55499c1b1a5ea658bb03204b96c.tar.bz2 urpmi-01508b09ee68c55499c1b1a5ea658bb03204b96c.tar.xz urpmi-01508b09ee68c55499c1b1a5ea658bb03204b96c.zip |
create urpm::msg::ask_yes_or_no() to remove duplication
Diffstat (limited to 'urpmi')
-rwxr-xr-x | urpmi | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -538,7 +538,7 @@ have to be removed for others to be upgraded:\n%s\n", $list); print "$msg\n"; } else { my $yesexpr = N("Yy"); - $force || message_input_($msg . N(" (y/N) "), boolean => 1) =~ /[$yesexpr]/ or exit 0; + $force || urpm::msg::ask_yes_or_no($msg) or exit 0; } } @@ -633,13 +633,13 @@ my $exit_code = urpm::main_loop::run($urpm, $state, 0; } else { my $yesexpr = N("Yy"); - $force || message_input_("$msg$msg2" . N(" (y/N) "), boolean => 1) =~ /[$yesexpr]/; + $force || urpm::msg::ask_yes_or_no("$msg$msg2"); } }, ask_yes_or_no => sub { my ($_title, $msg) = @_; # graphical title my $yesexpr = N("Yy"); - $force || message_input_($msg . N(" (y/N) "), boolean => 1) =~ /[$yesexpr]/; + $force || urpm::msg::ask_yes_or_no($msg); }, need_restart => sub { my ($need_restart_formatted) = @_; |