summaryrefslogtreecommitdiffstats
path: root/perl-install/diskdrake
diff options
context:
space:
mode:
authorThierry Vignaud <thierry.vignaud@gmail.com>2016-03-18 14:35:34 +0100
committerThierry Vignaud <thierry.vignaud@gmail.com>2016-03-18 14:43:06 +0100
commitcd7ce13e2f90bf25cedfcec1a606948b7b9897df (patch)
tree4a266f0182f5962dd020dc2dd20a830d7a5d738a /perl-install/diskdrake
parent5c0a888ab6d2fa52d5d6bcbaf6530de71f744b47 (diff)
downloaddrakx-cd7ce13e2f90bf25cedfcec1a606948b7b9897df.tar
drakx-cd7ce13e2f90bf25cedfcec1a606948b7b9897df.tar.gz
drakx-cd7ce13e2f90bf25cedfcec1a606948b7b9897df.tar.bz2
drakx-cd7ce13e2f90bf25cedfcec1a606948b7b9897df.tar.xz
drakx-cd7ce13e2f90bf25cedfcec1a606948b7b9897df.zip
fix partitions not initially displayed (mga#17564)
Diffstat (limited to 'perl-install/diskdrake')
-rw-r--r--perl-install/diskdrake/hd_gtk.pm6
1 files changed, 4 insertions, 2 deletions
diff --git a/perl-install/diskdrake/hd_gtk.pm b/perl-install/diskdrake/hd_gtk.pm
index 68295879d..47d47472a 100644
--- a/perl-install/diskdrake/hd_gtk.pm
+++ b/perl-install/diskdrake/hd_gtk.pm
@@ -114,10 +114,13 @@ sub main {
$notebook_widget->signal_connect(realize => $update_all);
$w->sync;
$notebook_widget->set_current_page(0);
+ # there's always at least one child (at least a button for create a new part on empty discs):
+ my @children = $current_kind->{display_box} ? $current_kind->{display_box}->get_children : ();
# workaround for $notebook_widget being realized too early:
- if (!$done_button) {
+ if (!@children ||!$done_button) {
$notebook_widget->set_current_page(-1);
$notebook_widget->set_current_page(0);
+ undef $initializing;
$update_all->(2);
}
$done_button->grab_focus;
@@ -127,7 +130,6 @@ sub main {
if $::isStandalone;
}
- undef $initializing;
$w->main;
}