summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--NEWS3
-rwxr-xr-xmdkapplet25
2 files changed, 24 insertions, 4 deletions
diff --git a/NEWS b/NEWS
index 9b6cb1a9..ce0b62f5 100644
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,6 @@
+- mdkapplet
+ o add a banner and pack Ok button to the right in success dialog
+
Version 2.51 - 7 October 2008
- mdkapplet
diff --git a/mdkapplet b/mdkapplet
index 4cfae24a..245133a4 100755
--- a/mdkapplet
+++ b/mdkapplet
@@ -336,10 +336,7 @@ sub harvester {
N("Installation logs can be found in '%s'", $log_file)
);
} else {
- ugtk2::ask_warn(N("Congratulations"),
- N("Upgrade to Mandriva %s release was successfull.", $new_distro->{version}),
- N("You should restart your system.")
- );
+ congratulations();
}
} elsif ($checker_pid && $checker_pid == $childpid) {
undef $checker_pid;
@@ -373,6 +370,26 @@ sub restart_applet() {
exec($0, '--auto-update');
}
+sub congratulations {
+ local $mygtk2::left_padding = 0;
+ my $width = 500;
+ my $w = ugtk2->new(N("Congratulations"));
+ gtkadd($w->{window},
+ gtknew('VBox', children_tight => [
+ get_banner(),
+ gtknew('Label_Left', text => N("Upgrade to Mandriva %s release was successfull.", $new_distro->{version}),
+ # workaround infamous 6 years old gnome bug #101968:
+ width => $width - 50),
+ gtknew('Label_Left', text => N("You should restart your system."),
+ # workaround infamous 6 years old gnome bug #101968:
+ width => $width - 50),
+ create_okcancel($w, N("Ok")),
+ ]),
+ );
+ $w->{ok}->grab_focus;
+ $w->main;
+}
+
sub get_banner() {
Gtk2::Banner->new(
(find { -e $_ }