summaryrefslogtreecommitdiffstats
path: root/control-center
diff options
context:
space:
mode:
authorThierry Vignaud <thierry.vignaud@gmail.com>2016-10-31 16:22:53 +0100
committerThierry Vignaud <thierry.vignaud@gmail.com>2016-10-31 18:02:46 +0100
commit610c347727e894a7fb0f8555bf5f6a44c3f70e97 (patch)
treee318db1b361005c72466ce2f7dd560a90ebabac3 /control-center
parentd05c8366ea6fc63b2023e0e7290438264c7ed705 (diff)
downloadcontrol-center-610c347727e894a7fb0f8555bf5f6a44c3f70e97.tar
control-center-610c347727e894a7fb0f8555bf5f6a44c3f70e97.tar.gz
control-center-610c347727e894a7fb0f8555bf5f6a44c3f70e97.tar.bz2
control-center-610c347727e894a7fb0f8555bf5f6a44c3f70e97.tar.xz
control-center-610c347727e894a7fb0f8555bf5f6a44c3f70e97.zip
fix wrong methods
we were crashing with: Can't locate object method "get_allocated_width" via package "Gtk3::Gdk::Pixbuf" at ./control-center line 1062. conversion done in commit 1981bc71c664e541c422c17c33dc449f0bf61d16 was wrong as PixBuf doesn't herit from Gtk3::Widget
Diffstat (limited to 'control-center')
-rwxr-xr-xcontrol-center4
1 files changed, 2 insertions, 2 deletions
diff --git a/control-center b/control-center
index 6247f5cd..f73aaeeb 100755
--- a/control-center
+++ b/control-center
@@ -1054,7 +1054,7 @@ $wait_darea->signal_connect(draw => sub {
$wait_darea->{first_expose} = 1;
my $size = $wait_darea->{size};
my ($d_width, $d_height) = ($size->{width}, $size->{height});
- ($w->{pix_width}, $w->{pix_height}) = ($pixbuf->get_allocated_width, $pixbuf->get_allocated_height);
+ ($w->{pix_width}, $w->{pix_height}) = ($pixbuf->get_width, $pixbuf->get_height);
my ($txt_width, $txt_height) = $wait_darea->{layout}->get_pixel_size;
$w->{pix_yy} = ($d_width - $w->{pix_width})/2;
$w->{pix_xx} = ($d_height - $w->{pix_height} - $txt_height)/2;
@@ -1522,7 +1522,7 @@ sub render_shiner {
sub scale {
my ($pixbuf, $gain) = @_;
- my ($width, $height) = ($pixbuf->get_allocated_height, $pixbuf->get_allocated_width);
+ my ($width, $height) = ($pixbuf->get_height, $pixbuf->get_width);
$pixbuf->scale_simple($height+$gain, $width+$gain, 'hyper');
}