[Xfce4-commits] <midori:master> Display Open Link in Foreground/ Background Tab

Christian Dywan noreply at xfce.org
Sun Nov 15 02:02:01 CET 2009


Updating branch refs/heads/master
         to fc10f156d23d5884cdd826257e59b545b101db0e (commit)
       from 1324c1db318f2fbc0fdfff5856a9ed2631553576 (commit)

commit fc10f156d23d5884cdd826257e59b545b101db0e
Author: Christian Dywan <christian at twotoasts.de>
Date:   Sat Nov 14 23:54:28 2009 +0100

    Display Open Link in Foreground/ Background Tab

 midori/midori-view.c |   13 +++++++++++++
 1 files changed, 13 insertions(+), 0 deletions(-)

diff --git a/midori/midori-view.c b/midori/midori-view.c
index d2419e3..e7ce2d7 100644
--- a/midori/midori-view.c
+++ b/midori/midori-view.c
@@ -1515,6 +1515,14 @@ midori_web_view_menu_new_tab_activate_cb (GtkWidget*  widget,
 }
 
 static void
+midori_web_view_menu_background_tab_activate_cb (GtkWidget*  widget,
+                                                 MidoriView* view)
+{
+    g_signal_emit (view, signals[NEW_TAB], 0, view->link_uri,
+                   !view->open_tabs_in_the_background);
+}
+
+static void
 midori_web_view_menu_search_web_activate_cb (GtkWidget*  widget,
                                              MidoriView* view)
 {
@@ -1720,6 +1728,11 @@ webkit_web_view_populate_popup_cb (WebKitWebView* web_view,
             _("Open Link in New _Tab"), STOCK_TAB_NEW,
             G_CALLBACK (midori_web_view_menu_new_tab_activate_cb), widget);
         midori_view_insert_menu_item (menu_shell, -1,
+            view->open_tabs_in_the_background
+            ? _("Open Link in _Foreground Tab")
+            : _("Open Link in _Background Tab"), STOCK_TAB_NEW,
+            G_CALLBACK (midori_web_view_menu_background_tab_activate_cb), widget);
+        midori_view_insert_menu_item (menu_shell, -1,
             _("Open Link in New _Window"), STOCK_WINDOW_NEW,
             G_CALLBACK (midori_web_view_menu_new_window_activate_cb), widget);
         midori_view_insert_menu_item (menu_shell, -1,



More information about the Xfce4-commits mailing list