[notification-daemon] Show the dock on both left and right click



commit 9e9a2ef75b60e033d10ea4b004f178ce18ad8c21
Author: William Jon McCann <jmccann redhat com>
Date:   Fri Oct 8 20:34:55 2010 -0400

    Show the dock on both left and right click

 src/nd-queue.c |   23 +++++++++++++++++++++--
 1 files changed, 21 insertions(+), 2 deletions(-)
---
diff --git a/src/nd-queue.c b/src/nd-queue.c
index ae8be4c..a07edd2 100644
--- a/src/nd-queue.c
+++ b/src/nd-queue.c
@@ -1096,8 +1096,7 @@ popup_dock (NdQueue *queue,
 }
 
 static void
-on_status_icon_activate (GtkStatusIcon *status_icon,
-                         NdQueue       *queue)
+show_dock (NdQueue *queue)
 {
         /* clear the bubble queue since the user will be looking at a
            full list now */
@@ -1108,6 +1107,22 @@ on_status_icon_activate (GtkStatusIcon *status_icon,
 }
 
 static void
+on_status_icon_popup_menu (GtkStatusIcon *status_icon,
+                           guint          button,
+                           guint          activate_time,
+                           NdQueue       *queue)
+{
+        show_dock (queue);
+}
+
+static void
+on_status_icon_activate (GtkStatusIcon *status_icon,
+                         NdQueue       *queue)
+{
+        show_dock (queue);
+}
+
+static void
 on_status_icon_visible_notify (GtkStatusIcon *icon,
                                GParamSpec    *pspec,
                                NdQueue       *queue)
@@ -1140,6 +1155,10 @@ update_idle (NdQueue *queue)
                                           G_CALLBACK (on_status_icon_activate),
                                           queue);
                         g_signal_connect (queue->priv->status_icon,
+                                          "popup-menu",
+                                          G_CALLBACK (on_status_icon_popup_menu),
+                                          queue);
+                        g_signal_connect (queue->priv->status_icon,
                                           "notify::visible",
                                           G_CALLBACK (on_status_icon_visible_notify),
                                           queue);



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]