summaryrefslogtreecommitdiffstats
path: root/perl-install/diskdrake
diff options
context:
space:
mode:
authorThierry Vignaud <thierry.vignaud@gmail.com>2015-02-19 09:36:57 +0100
committerThierry Vignaud <thierry.vignaud@gmail.com>2015-02-19 10:06:47 +0100
commit5299ba867274d525787d76f84fbfaaa6ff1b5370 (patch)
treeb97f9684b0d28715f66f155a04f50f619dcf6a82 /perl-install/diskdrake
parent3bc232ec927ecb363b121fb7255a29e77b738cd1 (diff)
downloaddrakx-5299ba867274d525787d76f84fbfaaa6ff1b5370.tar
drakx-5299ba867274d525787d76f84fbfaaa6ff1b5370.tar.gz
drakx-5299ba867274d525787d76f84fbfaaa6ff1b5370.tar.bz2
drakx-5299ba867274d525787d76f84fbfaaa6ff1b5370.tar.xz
drakx-5299ba867274d525787d76f84fbfaaa6ff1b5370.zip
workaround too wide togglebuttons with empty label
gtk+3 and/or Adwaita makes togglebuttons with empty label being at least 34px wide whereas when using ->new instead of ->new_with_label, they can be only 18px wide... ...which is still too much when we sized them to eg 5px and cause their container to enlarge
Diffstat (limited to 'perl-install/diskdrake')
-rw-r--r--perl-install/diskdrake/hd_gtk.pm4
1 files changed, 2 insertions, 2 deletions
diff --git a/perl-install/diskdrake/hd_gtk.pm b/perl-install/diskdrake/hd_gtk.pm
index 63d52ecb2..a2a791cf7 100644
--- a/perl-install/diskdrake/hd_gtk.pm
+++ b/perl-install/diskdrake/hd_gtk.pm
@@ -354,8 +354,8 @@ sub create_buttons4partitions {
}
my $info = $entry->{mntpoint} || $entry->{device_LABEL} || '';
$info .= "\n" . ($entry->{size} ? formatXiB($entry->{size}, 512) : N("Unknown")) if $info;
- my $w = Gtk3::ToggleButton->new_with_label($info) or internal_error('new_with_label');
- $w->get_child->set_ellipsize('end');
+ my $w = ($info ? Gtk3::ToggleButton->new_with_label($info) : Gtk3::ToggleButton->new) or internal_error('new_with_label');
+ $info and $w->get_child->set_ellipsize('end');
$w->set_tooltip_text($info);
$w->signal_connect(clicked => sub {
$current_button != $w or return;