From d5b10a973bd4ec474edf3bfa29df4458d2519e85 Mon Sep 17 00:00:00 2001 From: Thierry Vignaud Date: Mon, 18 Aug 2008 11:34:18 +0000 Subject: (new,may_destroy) track windows in order to be able to set the proper transient hint (really fixing focus bug (#42750) which got unfixed after fixing vivication) --- perl-install/mygtk2.pm | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'perl-install/mygtk2.pm') diff --git a/perl-install/mygtk2.pm b/perl-install/mygtk2.pm index 3067df65f..8cb691002 100644 --- a/perl-install/mygtk2.pm +++ b/perl-install/mygtk2.pm @@ -1182,7 +1182,13 @@ sub flush() { sub may_destroy { my ($w) = @_; - $w->destroy if $w; + return if !$w; + @::main_windows = difference2(\@::main_windows, [ $w->{real_window} ]); + if ($::main_window eq $w->{real_window}) { + undef $::main_window; + $::main_window = $::main_windows[-1]; + } + $w->destroy; } sub root_window() { -- cgit v1.2.1