summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThierry Vignaud <thierry.vignaud@gmail.com>2013-11-06 18:32:25 +0100
committerThierry Vignaud <thierry.vignaud@gmail.com>2013-11-24 23:28:15 +0100
commitfadc8b97ed98977bf264d87d62c33e779f299716 (patch)
tree7241ff524d60affadd70a3704ec3b4b2fb913b06
parent6b45a0f7bf02658ffbdc5398225ba86982bed6be (diff)
downloaddrakx-fadc8b97ed98977bf264d87d62c33e779f299716.tar
drakx-fadc8b97ed98977bf264d87d62c33e779f299716.tar.gz
drakx-fadc8b97ed98977bf264d87d62c33e779f299716.tar.bz2
drakx-fadc8b97ed98977bf264d87d62c33e779f299716.tar.xz
drakx-fadc8b97ed98977bf264d87d62c33e779f299716.zip
fix retrieving allocated size
-rw-r--r--perl-install/mygtk3.pm6
1 files changed, 3 insertions, 3 deletions
diff --git a/perl-install/mygtk3.pm b/perl-install/mygtk3.pm
index c41320b15..24cafc46f 100644
--- a/perl-install/mygtk3.pm
+++ b/perl-install/mygtk3.pm
@@ -790,7 +790,7 @@ sub _gtk__MDV_Notebook {
$w->signal_connect('size-allocate' => sub {
my (undef, $requisition) = @_;
state $width ||= $right_bg_width;
- $box->set_size_request($width, $requisition->height);
+ $box->set_size_request($width, $requisition->{height});
});
$_->set_property('no-show-all', 1) foreach $selection_bar, $selection_arrow;
bless($w, 'Gtk3::MDV_Notebook');
@@ -1320,7 +1320,7 @@ sub _create_Window {
my ($wi, $he);
$w->signal_connect(size_allocate => sub {
my (undef, $event) = @_;
- my @w_size = $event->values;
+ my @w_size = @$event{qw(height width)};
# ignore bogus sizing events:
return if $w_size[2] < 5;
@@ -1635,7 +1635,7 @@ sub move_selection {
my $layout = $w->{layout};
$layout->{arrow_ydiff} ||=
($w->{selection_arrow}->get_pixbuf->get_height - $w->{selection_bar}->get_pixbuf->get_height)/2;
- my $bar_y = $label->get_allocation->y - ($w->{selection_bar}->get_pixbuf->get_height - $label->allocation->height)/2;
+ my $bar_y = $label->get_allocation->{y} - ($w->{selection_bar}->get_pixbuf->get_height - $label->get_allocation->{height})/2;
$layout->move($w->{selection_bar}, 0, $bar_y);
$layout->move($w->{selection_arrow}, $w->{arrow_x}, $bar_y - $layout->{arrow_ydiff}); # arrow is higer
$_->show foreach $w->{selection_bar}, $w->{selection_arrow};