[gnome-documents] view: use gtk_menu_popup_for_device()



commit 0545ea93971acb365866b934e953a1ef1494f4ba
Author: Cosimo Cecchi <cosimoc gnome org>
Date:   Fri Aug 26 12:52:37 2011 -0400

    view: use gtk_menu_popup_for_device()

 src/lib/gd-utils.c |    8 --------
 src/lib/gd-utils.h |    4 ----
 src/view.js        |    2 +-
 3 files changed, 1 insertions(+), 13 deletions(-)
---
diff --git a/src/lib/gd-utils.c b/src/lib/gd-utils.c
index d30f8f1..52d5289 100644
--- a/src/lib/gd-utils.c
+++ b/src/lib/gd-utils.c
@@ -305,11 +305,3 @@ gd_gdk_event_get_position (GdkEvent *event,
   if (y)
     *y = button_ev->y;
 }
-
-void
-gd_gtk_menu_popup (GtkMenu *menu,
-                   guint button,
-                   guint32 timestamp)
-{
-  gtk_menu_popup (menu, NULL, NULL, NULL, NULL, button, timestamp);
-}
diff --git a/src/lib/gd-utils.h b/src/lib/gd-utils.h
index 9d1acfa..18ad1f2 100644
--- a/src/lib/gd-utils.h
+++ b/src/lib/gd-utils.h
@@ -56,10 +56,6 @@ void gd_sidebar_store_set (GtkListStore *store,
                            const gchar *icon_name,
                            gboolean heading);
 
-void gd_gtk_menu_popup (GtkMenu *menu,
-                        guint button,
-                        guint32 timestamp);
-
 guint gd_gdk_event_get_button (GdkEvent *event);
 void  gd_gdk_event_get_position (GdkEvent *event,
                                  gdouble *x,
diff --git a/src/view.js b/src/view.js
index 0c2c6da..0c361ef 100644
--- a/src/view.js
+++ b/src/view.js
@@ -130,7 +130,7 @@ View.prototype = {
         let isFavorite = this._treeModel.get_value(iter, TrackerModel.ModelColumns.FAVORITE);
 
         let menu = new ContextMenu(urn, isFavorite);
-        Gd.gtk_menu_popup(menu.widget, button, timestamp);
+        menu.widget.popup_for_device(null, null, null, null, null, null, button, timestamp);
 
         return true;
     },



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