From: Christian Dywan Date: Tue, 22 Mar 2011 23:26:51 +0000 (+0100) Subject: Make speed dial in blank tabs mandatory X-Git-Url: https://spindle.queued.net/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0163806daa7ee3d6778cdb27665ea3dffc15c8c3;p=midori Make speed dial in blank tabs mandatory Fixes: https://bugs.launchpad.net/midori/+bug/699961 --- diff --git a/midori/midori-browser.c b/midori/midori-browser.c index c2e2934b..4399236e 100644 --- a/midori/midori-browser.c +++ b/midori/midori-browser.c @@ -99,7 +99,6 @@ struct _MidoriBrowser gboolean show_navigationbar; gboolean show_statusbar; - gboolean speed_dial_in_new_tabs; guint maximum_history_age; gchar* location_entry_search; gchar* news_aggregator; @@ -300,7 +299,7 @@ _midori_browser_update_interface (MidoriBrowser* browser) midori_view_get_next_page (view) != NULL); gtk_action_set_visible (_action_by_name (browser, "AddSpeedDial"), - browser->speed_dial_in_new_tabs && !midori_view_is_blank (view)); + !midori_view_is_blank (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", midori_view_can_view_source (view)); @@ -6172,7 +6171,6 @@ _midori_browser_update_settings (MidoriBrowser* browser) "show-bookmarkbar", &show_bookmarkbar, "show-panel", &show_panel, "show-statusbar", &browser->show_statusbar, - "speed-dial-in-new-tabs", &browser->speed_dial_in_new_tabs, "toolbar-style", &toolbar_style, "toolbar-items", &toolbar_items, "last-web-search", &last_web_search, @@ -6306,8 +6304,6 @@ midori_browser_settings_notify (MidoriWebSettings* web_settings, browser->show_navigationbar = g_value_get_boolean (&value); else if (name == g_intern_string ("show-statusbar")) browser->show_statusbar = g_value_get_boolean (&value); - else if (name == g_intern_string ("speed-dial-in-new-tabs")) - browser->speed_dial_in_new_tabs = g_value_get_boolean (&value); else if (name == g_intern_string ("search-engines-in-completion")) { if (g_value_get_boolean (&value)) diff --git a/midori/midori-preferences.c b/midori/midori-preferences.c index 991befbe..4837e815 100644 --- a/midori/midori-preferences.c +++ b/midori/midori-preferences.c @@ -357,8 +357,6 @@ midori_preferences_set_settings (MidoriPreferences* preferences, } button = katze_property_proxy (settings, "show-crash-dialog", NULL); INDENTED_ADD (button); - button = katze_property_proxy (settings, "speed-dial-in-new-tabs", NULL); - SPANNED_ADD (button); FRAME_NEW (_("Transfers")); #if !HAVE_HILDON label = katze_property_label (settings, "download-folder"); diff --git a/midori/midori-view.c b/midori/midori-view.c index 238ca976..c3a903f1 100644 --- a/midori/midori-view.c +++ b/midori/midori-view.c @@ -89,7 +89,6 @@ struct _MidoriView GtkWidget* thumb_view; KatzeArray* news_feeds; - gboolean speed_dial_in_new_tabs; gchar* download_manager; gchar* news_aggregator; gboolean middle_click_opens_selection; @@ -2713,7 +2712,7 @@ midori_view_populate_popup (MidoriView* view, gtk_action_group_get_action (actions, "BookmarkAdd")); gtk_menu_shell_append (menu_shell, menuitem); - if (view->speed_dial_in_new_tabs && !midori_view_is_blank (view) + if (!midori_view_is_blank (view) && strcmp ("/", sokoke_set_config_dir (NULL))) { menuitem = sokoke_action_create_popup_menu_item ( @@ -3362,7 +3361,6 @@ _midori_view_set_settings (MidoriView* view, g_free (view->news_aggregator); g_object_get (view->settings, - "speed-dial-in-new-tabs", &view->speed_dial_in_new_tabs, "download-manager", &view->download_manager, "news-aggregator", &view->news_aggregator, "zoom-text-and-images", &zoom_text_and_images, @@ -3420,9 +3418,7 @@ midori_view_settings_notify_cb (MidoriWebSettings* settings, g_value_init (&value, pspec->value_type); g_object_get_property (G_OBJECT (view->settings), name, &value); - if (name == g_intern_string ("speed-dial-in-new-tabs")) - view->speed_dial_in_new_tabs = g_value_get_boolean (&value); - else if (name == g_intern_string ("download-manager")) + if (name == g_intern_string ("download-manager")) katze_assign (view->download_manager, g_value_dup_string (&value)); else if (name == g_intern_string ("news-aggregator")) katze_assign (view->news_aggregator, g_value_dup_string (&value)); @@ -3900,7 +3896,7 @@ midori_view_set_uri (MidoriView* view, if (g_getenv ("MIDORI_UNARMED") == NULL) { - if (view->speed_dial_in_new_tabs && !strcmp (uri, "")) + if (!strcmp (uri, "")) { #if !WEBKIT_CHECK_VERSION (1, 1, 14) SoupServer* res_server; diff --git a/midori/midori-websettings.c b/midori/midori-websettings.c index 4e5ee10e..6994452d 100644 --- a/midori/midori-websettings.c +++ b/midori/midori-websettings.c @@ -636,6 +636,8 @@ midori_web_settings_class_init (MidoriWebSettingsClass* class) * Show spee dial in newly opened tabs. * * Since: 0.1.7 + * + * Deprecated: 0.3.4 */ g_object_class_install_property (gobject_class, PROP_SPEED_DIAL_IN_NEW_TABS,