aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'calendar/main.c')
-rw-r--r--calendar/main.c26
1 files changed, 26 insertions, 0 deletions
diff --git a/calendar/main.c b/calendar/main.c
index 5ccdeee3ff..462e71a06a 100644
--- a/calendar/main.c
+++ b/calendar/main.c
@@ -251,22 +251,48 @@ quit_cmd (void)
}
}
+/* Sets a clock cursor for the specified calendar window */
+static void
+set_clock_cursor (GnomeCalendar *gcal)
+{
+ GdkCursor *cursor;
+
+ cursor = gdk_cursor_new (GDK_WATCH);
+ gdk_window_set_cursor (GTK_WIDGET (gcal)->window, cursor);
+ gdk_cursor_destroy (cursor);
+ gdk_flush ();
+}
+
+/* Resets the normal cursor for the specified calendar window */
+static void
+set_normal_cursor (GnomeCalendar *gcal)
+{
+ gdk_window_set_cursor (GTK_WIDGET (gcal)->window, NULL);
+ gdk_flush ();
+}
+
static void
previous_clicked (GtkWidget *widget, GnomeCalendar *gcal)
{
+ set_clock_cursor (gcal);
gnome_calendar_previous (gcal);
+ set_normal_cursor (gcal);
}
static void
next_clicked (GtkWidget *widget, GnomeCalendar *gcal)
{
+ set_clock_cursor (gcal);
gnome_calendar_next (gcal);
+ set_normal_cursor (gcal);
}
static void
today_clicked (GtkWidget *widget, GnomeCalendar *gcal)
{
+ set_clock_cursor (gcal);
gnome_calendar_goto_today (gcal);
+ set_normal_cursor (gcal);
}
static void