summaryrefslogtreecommitdiffstats
path: root/clock.pl
diff options
context:
space:
mode:
Diffstat (limited to 'clock.pl')
-rwxr-xr-xclock.pl22
1 files changed, 11 insertions, 11 deletions
diff --git a/clock.pl b/clock.pl
index 9ebf93c5..3c2fe318 100755
--- a/clock.pl
+++ b/clock.pl
@@ -75,7 +75,17 @@ $my_win->{window}->add(gtkpack_(Gtk2::VBox->new(0,0),
),
),
0, gtkadd(gtkset_layout(Gtk2::HButtonBox->new, 'end'),
- gtksignal_connect(Gtk2::Button->new(N("OK")),
+ gtksignal_connect(Gtk2::Button->new_from_stock('gtk-cancel'), clicked => sub { ugtk2->exit(0) }),
+ $button_reset = gtksignal_connect(Gtk2::Button->new_from_stock('gtk-revert-to-saved'), clicked => sub {
+ $its_reset = 1;
+ $timer = Glib::Timeout->add(120, \&update_time);
+ Repaint($drawing_area, 1);
+ $calendar->select_month($old_month, $old_year);
+ $calendar->select_day($old_day);
+ $button_reset->set_sensitive(0);
+ $its_reset = 0;
+ }),
+ gtksignal_connect(Gtk2::Button->new_from_stock('gtk-ok'),
clicked => sub {
my ($year, $month, $day) = $calendar->get_date;
$month++;
@@ -86,16 +96,6 @@ $my_win->{window}->add(gtkpack_(Gtk2::VBox->new(0,0),
system("dcop kicker Panel restart") if $ENV{DESKTOP} eq 'kde';
ugtk2->exit(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 = Glib::Timeout->add(120, \&update_time);
- Repaint($drawing_area, 1);
- $calendar->select_month($old_month, $old_year);
- $calendar->select_day($old_day);
- $button_reset->set_sensitive(0);
- $its_reset = 0;
- })
)
)
);