diff options
author | Thierry Vignaud <tvignaud@mandriva.org> | 2003-01-29 08:23:46 +0000 |
---|---|---|
committer | Thierry Vignaud <tvignaud@mandriva.org> | 2003-01-29 08:23:46 +0000 |
commit | 77ff97a9e53da3bdb8a02c7b47d0f8ed595a827b (patch) | |
tree | 3169cb3a312c3135e23a5b3f9dccabbf8bded71c | |
parent | 4fc0823453f0ecb58d1e9ba824560ea769c24803 (diff) | |
download | control-center-77ff97a9e53da3bdb8a02c7b47d0f8ed595a827b.tar control-center-77ff97a9e53da3bdb8a02c7b47d0f8ed595a827b.tar.gz control-center-77ff97a9e53da3bdb8a02c7b47d0f8ed595a827b.tar.bz2 control-center-77ff97a9e53da3bdb8a02c7b47d0f8ed595a827b.tar.xz control-center-77ff97a9e53da3bdb8a02c7b47d0f8ed595a827b.zip |
(launch_xapp) simplify
-rwxr-xr-x | control-center | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/control-center b/control-center index 7a032ec6..483c47d3 100755 --- a/control-center +++ b/control-center @@ -697,15 +697,11 @@ sub launch_xapp { my $find_windows = sub { split '\n', `xwininfo -root -tree -int | grep '$name'` }; my @before = &$find_windows(); fork_("$exec; kill -USR1 $$"); - while (1) { - my @after = &$find_windows(); - while (@after ne $xx + @before) { - @after = &$find_windows(); - } - my $c = top(difference2(\@after, \@before)); - $c =~ /\s*([0-9]*)\s*/; - return $1; - } + my @after = &$find_windows(); + @after = &$find_windows() while @after ne $xx + @before; + my $c = top(difference2(\@after, \@before)); + $c =~ /\s*([0-9]*)\s*/; + return $1; } sub hide_socket_and_clean { |