From 0ce4b49fbc58931afc0ee6bb3647aef97b4b2039 Mon Sep 17 00:00:00 2001 From: Thierry Vignaud Date: Wed, 2 Nov 2016 15:45:20 +0100 Subject: kill {size} thus fix centering wait message + blinking icon while loading a tool --- NEWS | 1 + control-center | 5 +---- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/NEWS b/NEWS index c9e0b69c..9a1ef761 100644 --- a/NEWS +++ b/NEWS @@ -1,3 +1,4 @@ +- fix centering wait message + blinking icon while loading a tool - fix display "please wait" message while loading a tool Version 13.8 - 31 October 2016, Thierry Vignaud diff --git a/control-center b/control-center index 208be5d0..3c42d00e 100755 --- a/control-center +++ b/control-center @@ -1053,10 +1053,9 @@ $wait_darea->signal_connect(draw => sub { my ($w, $cr) = @_; return if !$wait_darea->get_realized; return unless $run_pixbuf; # some people got an expose event before we start an embedded tool - return unless $wait_darea->{size}; $wait_darea->{layout} ||= $wait_darea->create_pango_layout(N("Loading... Please wait")); my $pixbuf = $run_pixbufs{$run_counter} ||= mygtk3::_pixbuf_render_alpha($run_pixbuf, $run_counter); - my $size = $wait_darea->{size}; + my $size = $wait_darea->get_allocation; my ($d_width, $d_height) = ($size->{width}, $size->{height}); ($w->{pix_width}, $w->{pix_height}) = ($pixbuf->get_width, $pixbuf->get_height); my ($txt_width, $txt_height) = $wait_darea->{layout}->get_pixel_size; @@ -1253,8 +1252,6 @@ sub run_tool { $run_pixbuf = eval { gtkcreate_pixbuf($icon . "_128") }; $run_counter = 255; $run_counter_add = -5; - undef $wait_darea->{size}; - $wait_darea->{size} = $wait_darea->get_allocation; $timeout = Glib::Timeout->add(35, sub { my $w = $wait_darea; $w->queue_draw_area($w->{pix_yy}, $w->{pix_xx}, $w->{pix_width}, $w->{pix_height}); -- cgit v1.2.1