diff options
-rw-r--r-- | src/tab-chrome.c | 19 |
1 files changed, 2 insertions, 17 deletions
diff --git a/src/tab-chrome.c b/src/tab-chrome.c index aa7ed19..c45d500 100644 --- a/src/tab-chrome.c +++ b/src/tab-chrome.c @@ -30,20 +30,10 @@ #include "back-forward-button-box.h" #include "stop-reload-button.h" #include "uri-entry.h" +#include "home-button.h" #include "main-menu.h" #include "find-toolbar.h" -static void -home_clicked_cb(GtkToolButton G_GNUC_UNUSED *toolbutton, - MqTabChrome *chrome) -{ - const gchar *uri; - - uri = mq_config_get_string(chrome->config, "tabs.home"); - - mq_web_view_load_uri(chrome->web_view, uri); -} - static GtkWidget * navigation_toolbar_new(MqTabChrome *chrome, const gchar *uri) { @@ -70,12 +60,7 @@ navigation_toolbar_new(MqTabChrome *chrome, const gchar *uri) gtk_toolbar_insert(navigation_toolbar, uri_tool_item, -1); /* Home button */ - home_button = gtk_tool_button_new(gtk_image_new_from_icon_name( - "go-home", GTK_ICON_SIZE_SMALL_TOOLBAR), "Home"); - gtk_widget_set_tooltip_text(GTK_WIDGET(home_button), - "Load the home page"); - g_signal_connect(home_button, "clicked", - G_CALLBACK(home_clicked_cb), chrome); + home_button = mq_home_button_new(chrome->config, chrome->web_view); gtk_toolbar_insert(navigation_toolbar, home_button, -1); /* Menu button */ |