From e032366577d644b346fcb870d9150fb18b8edc5a Mon Sep 17 00:00:00 2001 From: Thierry Vignaud Date: Fri, 4 Apr 2003 07:49:39 +0000 Subject: - perl_checker fixes - ensure only one callback do regular parsing --- perl-install/standalone/logdrake | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'perl-install/standalone') diff --git a/perl-install/standalone/logdrake b/perl-install/standalone/logdrake index 3984ea162..9ee51926e 100755 --- a/perl-install/standalone/logdrake +++ b/perl-install/standalone/logdrake @@ -232,9 +232,11 @@ sub search { } local *F; +my $timer; sub parse_file { - my ($file, $descr) = @_;; + local *F = *F; + my ($file, $descr) = @_; $file =~ s/\.gz$//; my ($pbar, $win_pb); @@ -298,15 +300,13 @@ sub parse_file { local $_; while () {}; #to prevent to output the file twice.. # $log_text->set_point($log_text->get_length()); - my $timer = Gtk2->timeout_add(1000, \&input_callback); + $timer ||= Gtk2->timeout_add(1000, sub { + logcolorize($_) while ; + seek F, 0, 1; + }); } } -sub input_callback { - logcolorize($_) while ; - seek F, 0, 1; -} - ########################################################################################## -- cgit v1.2.1