summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2007-09-19 14:15:53 +0000
committerPascal Rigaux <pixel@mandriva.com>2007-09-19 14:15:53 +0000
commit4a89c725392fcb49befc0a60d251d75d9962b6b5 (patch)
tree77b56c05f136dddf9f90deb6befe13d1d0dce531
parentb323dd3df0352e75bd2bacf544246797e83ce6ae (diff)
downloaddrakx-4a89c725392fcb49befc0a60d251d75d9962b6b5.tar
drakx-4a89c725392fcb49befc0a60d251d75d9962b6b5.tar.gz
drakx-4a89c725392fcb49befc0a60d251d75d9962b6b5.tar.bz2
drakx-4a89c725392fcb49befc0a60d251d75d9962b6b5.tar.xz
drakx-4a89c725392fcb49befc0a60d251d75d9962b6b5.zip
restore banner on pop up messages (#33753)
the tricky part here is we need to differentiate the case when the empty box given in ugtk2.pm was really meant to be discarded (eg: diskdrake during install), but don't want to discard the child if it's useful (wait_message)
-rw-r--r--perl-install/install/NEWS1
-rw-r--r--perl-install/mygtk2.pm9
-rw-r--r--perl-install/ugtk2.pm1
3 files changed, 8 insertions, 3 deletions
diff --git a/perl-install/install/NEWS b/perl-install/install/NEWS
index cc170ee83..a6c0c0cf0 100644
--- a/perl-install/install/NEWS
+++ b/perl-install/install/NEWS
@@ -1,3 +1,4 @@
+- restore banner on pop up messages (#33753)
- handle /boot/xxx files on linux raid1
- when basesystem can't be selected, display the reason
- also load dm-zero for dmraid
diff --git a/perl-install/mygtk2.pm b/perl-install/mygtk2.pm
index 2278a8b93..2d6ea61f9 100644
--- a/perl-install/mygtk2.pm
+++ b/perl-install/mygtk2.pm
@@ -585,11 +585,16 @@ sub _gtk__MagicWindow {
any { !$_->isa('Gtk2::DrawingArea') && $_->visible } $::WizardTable->get_children;
};
- my $sub_child = delete $opts->{child} or internal_error("missing child");
+ my $sub_child = delete $opts->{child};
my $provided_banner = delete $opts->{banner};
+ if ($pop_it && $provided_banner) {
+ $sub_child = gtknew('VBox', children => [ 0, $provided_banner, if_($sub_child, 1, $sub_child) ]);
+ } else {
+ $sub_child ||= gtknew('VBox');
+ }
+
if ($pop_it) {
- $sub_child ||= gtknew('VBox', children_tight => [ $provided_banner ]) if $provided_banner;
$opts->{child} = $::isInstall ?
gtknew('Frame', shadow_type => 'out',
child => gtknew('Frame', shadow_type => 'none', border_width => 3, child => $sub_child)) :
diff --git a/perl-install/ugtk2.pm b/perl-install/ugtk2.pm
index f4f166238..54088e6d8 100644
--- a/perl-install/ugtk2.pm
+++ b/perl-install/ugtk2.pm
@@ -731,7 +731,6 @@ sub new {
pop_it => $o->{pop_it},
$::isInstall ? (banner => Gtk2::Banner->new($icon, $title || (get_default_step_items())[1])) : (),
$::isStandalone && $banner_title && $icon ? (banner => Gtk2::Banner->new($icon, $banner_title)) : (),
- child => gtknew('VBox'),
width => $opts{width}, height => $opts{height}, default_width => $opts{default_width}, default_height => $opts{default_height},
modal => $opts{modal} || $grab || $o->{grab} || $o->{modal} || $o->{transient},
no_Window_Manager => exists $opts{no_Window_Manager} ? $opts{no_Window_Manager} : !$::isStandalone,