From: Christian Dywan Date: Fri, 22 May 2009 22:07:52 +0000 (+0200) Subject: Don't show 'Add to speed dial' on blank pages X-Git-Url: https://spindle.queued.net/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=441db876476bbdd135e427f14547f3542d24e6a6;p=midori Don't show 'Add to speed dial' on blank pages --- diff --git a/midori/midori-browser.c b/midori/midori-browser.c index 8b70e8d8..6a4c38f8 100644 --- a/midori/midori-browser.c +++ b/midori/midori-browser.c @@ -262,7 +262,7 @@ _midori_browser_update_interface (MidoriBrowser* browser) midori_view_can_go_forward (MIDORI_VIEW (view))); gtk_action_set_visible (_action_by_name (browser, "AddSpeedDial"), - browser->speed_dial_in_new_tabs); + browser->speed_dial_in_new_tabs && !midori_view_is_blank (MIDORI_VIEW (view))); /* Currently views that don't support source, don't support saving either. If that changes, we need to think of something. */ _action_set_sensitive (browser, "SaveAs", diff --git a/midori/midori-view.c b/midori/midori-view.c index 5619378c..a7bd4133 100644 --- a/midori/midori-view.c +++ b/midori/midori-view.c @@ -1332,7 +1332,7 @@ webkit_web_view_populate_popup_cb (WebKitWebView* web_view, G_CALLBACK (midori_web_view_menu_action_activate_cb), view); gtk_widget_show (menuitem); - if (view->speed_dial_in_new_tabs) + if (view->speed_dial_in_new_tabs && !midori_view_is_blank (view)) { menuitem = gtk_image_menu_item_new_with_mnemonic (_("Add to Speed _dial")); gtk_menu_shell_append (GTK_MENU_SHELL (menu), menuitem);