[epiphany] Do not show weird context menu entries in app mode



commit ea9e139acb7a6373627e980b9beb8efad8d0d8e2
Author: Michael Catanzaro <mcatanzaro igalia com>
Date:   Wed Aug 27 09:08:34 2014 -0500

    Do not show weird context menu entries in app mode
    
    "Inspect element" and "Send Link by Email" should not be shown in app
    mdoe.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=699584

 src/ephy-window.c |   11 +++++++----
 1 files changed, 7 insertions(+), 4 deletions(-)
---
diff --git a/src/ephy-window.c b/src/ephy-window.c
index 50eb6a2..e8614d2 100644
--- a/src/ephy-window.c
+++ b/src/ephy-window.c
@@ -1855,6 +1855,13 @@ populate_context_menu (WebKitWebView *web_view,
                }
        }
 
+       g_signal_connect (web_view, "context-menu-dismissed",
+                         G_CALLBACK (context_menu_dismissed_cb),
+                         window);
+
+       if (app_mode)
+               return FALSE;
+
        if (is_document && !is_image && !is_media)
        {
                webkit_context_menu_append (context_menu,
@@ -1868,10 +1875,6 @@ populate_context_menu (WebKitWebView *web_view,
        webkit_context_menu_append (context_menu,
                                    webkit_context_menu_item_new_from_stock_action 
(WEBKIT_CONTEXT_MENU_ACTION_INSPECT_ELEMENT));
 
-       g_signal_connect (web_view, "context-menu-dismissed",
-                         G_CALLBACK (context_menu_dismissed_cb),
-                         window);
-
        return FALSE;
 }
 


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