diff options
author | Thierry Vignaud <tv@mandriva.org> | 2008-10-07 15:57:30 +0000 |
---|---|---|
committer | Thierry Vignaud <tv@mandriva.org> | 2008-10-07 15:57:30 +0000 |
commit | 4fcffb3801fe225dec1eb08138dd4ccdfe7f96bb (patch) | |
tree | 6e2ef7f5df59ee75db97828cee0d44a9470ccaa0 /mdkapplet | |
parent | f6552aae471d51d54b91b302581ab51e36b12d7b (diff) | |
download | mgaonline-4fcffb3801fe225dec1eb08138dd4ccdfe7f96bb.tar mgaonline-4fcffb3801fe225dec1eb08138dd4ccdfe7f96bb.tar.gz mgaonline-4fcffb3801fe225dec1eb08138dd4ccdfe7f96bb.tar.bz2 mgaonline-4fcffb3801fe225dec1eb08138dd4ccdfe7f96bb.tar.xz mgaonline-4fcffb3801fe225dec1eb08138dd4ccdfe7f96bb.zip |
(congratulations) extract it out of harvester() ; add a banner and
pack Ok button to the right
Diffstat (limited to 'mdkapplet')
-rwxr-xr-x | mdkapplet | 25 |
1 files changed, 21 insertions, 4 deletions
@@ -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 $_ } |