summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThierry Vignaud <tvignaud@mandriva.org>2003-07-10 14:41:25 +0000
committerThierry Vignaud <tvignaud@mandriva.org>2003-07-10 14:41:25 +0000
commit61d520cc59b83cce66d537b0ab7d14677a7c420b (patch)
tree331c796a8f8bca95d29896060d2aff3dd55ef01a
parentdc3418c48abbd08efaa7cb4c3f2b8d2f90fbb525 (diff)
downloadcontrol-center-61d520cc59b83cce66d537b0ab7d14677a7c420b.tar
control-center-61d520cc59b83cce66d537b0ab7d14677a7c420b.tar.gz
control-center-61d520cc59b83cce66d537b0ab7d14677a7c420b.tar.bz2
control-center-61d520cc59b83cce66d537b0ab7d14677a7c420b.tar.xz
control-center-61d520cc59b83cce66d537b0ab7d14677a7c420b.zip
fix timeout
-rwxr-xr-xclock.pl10
1 files changed, 5 insertions, 5 deletions
diff --git a/clock.pl b/clock.pl
index a8540d6b..9cf4721f 100755
--- a/clock.pl
+++ b/clock.pl
@@ -89,7 +89,7 @@ $my_win->{window}->add(gtkpack_(Gtk2::VBox->new(0,0),
gtksignal_connect(Gtk2::Button->new(N("Cancel")), clicked => sub { ugtk2->exit(0) }),
$button_reset = gtksignal_connect(Gtk2::Button->new(N("Reset")), clicked => sub {
$its_reset = 1;
- $timer = Gtk2->timeout_add(120, \&update_time);
+ $timer = Glib::Timeout->add(120, \&update_time);
Repaint($drawing_area, 1);
$calendar->select_month($old_month, $old_year);
$calendar->select_day($old_day);
@@ -134,7 +134,7 @@ $old_year += 1900;
$calendar->select_month($old_month, $old_year);
$calendar->select_day($old_day);
$button_reset->set_sensitive(0);
-$timer = Gtk2->timeout_add(120, \&update_time);
+$timer = Glib::Timeout->add(120, \&update_time);
$drawing_area->show;
$my_win->main;
@@ -146,7 +146,7 @@ sub update_time() {
};
sub cal_changed() {
- !$its_reset and $timer and Gtk2->timeout_remove($timer);
+ !$its_reset and $timer and Glib::Source->remove($timer);
$button_reset->set_sensitive(1);
}
@@ -161,7 +161,7 @@ sub changed() {
}
sub spinned() {
- Gtk2->timeout_remove($timer);
+ Glib::Source->remove($timer);
$button_reset->set_sensitive(1);
my (undef, undef, undef, @values) = localtime(time());
@@ -174,7 +174,7 @@ sub motion_event {
my ($widget, $event) = @_;
$pressed or return;
if ($first) {
- Gtk2->timeout_remove($timer);
+ Glib::Source->remove($timer);
$Radian = determine_radian($event->x, $event->y);
$button_reset->set_sensitive(1);
}