aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui/alarm-notify/alarm-queue.c
diff options
context:
space:
mode:
authorSrinivasa Ragavan <sragavan@src.gnome.org>2007-05-04 12:14:18 +0800
committerSrinivasa Ragavan <sragavan@src.gnome.org>2007-05-04 12:14:18 +0800
commit5d17a26e74f774d5a57822915df678ac42aa63fd (patch)
tree233d0b8f263ea32a858273fa1ac7834561f018c4 /calendar/gui/alarm-notify/alarm-queue.c
parent4d78fe7c0ce0c8160ff89a7f10d20f5a3084f3de (diff)
downloadgsoc2013-evolution-5d17a26e74f774d5a57822915df678ac42aa63fd.tar
gsoc2013-evolution-5d17a26e74f774d5a57822915df678ac42aa63fd.tar.gz
gsoc2013-evolution-5d17a26e74f774d5a57822915df678ac42aa63fd.tar.bz2
gsoc2013-evolution-5d17a26e74f774d5a57822915df678ac42aa63fd.tar.lz
gsoc2013-evolution-5d17a26e74f774d5a57822915df678ac42aa63fd.tar.xz
gsoc2013-evolution-5d17a26e74f774d5a57822915df678ac42aa63fd.tar.zst
gsoc2013-evolution-5d17a26e74f774d5a57822915df678ac42aa63fd.zip
Fix for bug #415562
svn path=/trunk/; revision=33480
Diffstat (limited to 'calendar/gui/alarm-notify/alarm-queue.c')
-rw-r--r--calendar/gui/alarm-notify/alarm-queue.c19
1 files changed, 19 insertions, 0 deletions
diff --git a/calendar/gui/alarm-notify/alarm-queue.c b/calendar/gui/alarm-notify/alarm-queue.c
index 5f5060e8e8..b5a2f52ffb 100644
--- a/calendar/gui/alarm-notify/alarm-queue.c
+++ b/calendar/gui/alarm-notify/alarm-queue.c
@@ -1344,6 +1344,7 @@ tray_icon_clicked_cb (GtkWidget *widget, GdkEventButton *event, gpointer user_da
gtk_widget_destroy (GTK_WIDGET (tray_icon));
tray_image = NULL;
#else
+ gtk_status_icon_set_visible (tray_icon, FALSE);
g_object_unref (tray_icon);
#endif
tray_icon = NULL;
@@ -1366,6 +1367,21 @@ icon_activated (GtkStatusIcon *icon)
tray_icon_clicked_cb (NULL, &event, NULL);
}
+
+static void
+popup_menu (GtkStatusIcon *icon, guint button, guint activate_time)
+{
+ if (button == 3) {
+ /* right click */
+ GdkEventButton event;
+
+ event.type = GDK_BUTTON_PRESS;
+ event.button = 3;
+ event.time = gtk_get_current_event_time ();
+
+ tray_icon_clicked_cb (NULL, &event, NULL);
+ }
+}
#endif
static gboolean
@@ -1495,6 +1511,9 @@ display_notification (time_t trigger, CompQueuedAlarms *cqa,
gtk_status_icon_set_from_pixbuf (tray_icon, e_icon_factory_get_icon ("stock_appointment-reminder", E_ICON_SIZE_LARGE_TOOLBAR));
g_signal_connect (G_OBJECT (tray_icon), "activate",
G_CALLBACK (icon_activated), NULL);
+ g_signal_connect (G_OBJECT (tray_icon), "popup-menu",
+ G_CALLBACK (popup_menu), NULL);
+
}
#endif