diff options
author | Patrick McDermott <pj@pehjota.net> | 2017-09-17 03:13:43 (EDT) |
---|---|---|
committer | Patrick McDermott <pj@pehjota.net> | 2017-09-17 03:14:46 (EDT) |
commit | 0ad2ce4e81dce4acb200da2aa761b8dcaa78118d (patch) | |
tree | 835628df02973280e9c91853d938de4c7d9033e2 /src | |
parent | c382b0211cf4fa55ce90b94d06571e3e6d8bd52c (diff) | |
download | marquee-0ad2ce4e81dce4acb200da2aa761b8dcaa78118d.zip marquee-0ad2ce4e81dce4acb200da2aa761b8dcaa78118d.tar.gz marquee-0ad2ce4e81dce4acb200da2aa761b8dcaa78118d.tar.bz2 |
src/tab-chrome.[ch]: Save navigation toolbar buttons
Diffstat (limited to 'src')
-rw-r--r-- | src/tab-chrome.c | 17 | ||||
-rw-r--r-- | src/tab-chrome.h | 2 |
2 files changed, 9 insertions, 10 deletions
diff --git a/src/tab-chrome.c b/src/tab-chrome.c index a66da19..d187e70 100644 --- a/src/tab-chrome.c +++ b/src/tab-chrome.c @@ -35,18 +35,14 @@ navigation_toolbar_new(MqTabChrome *chrome, gchar *uri) navigation_toolbar = GTK_TOOLBAR(gtk_toolbar_new()); /* Back button */ - gtk_toolbar_insert(navigation_toolbar, - gtk_tool_button_new( - gtk_image_new_from_icon_name("go-previous", 16), - "Back"), - -1); + chrome->back_button = gtk_tool_button_new( + gtk_image_new_from_icon_name("go-previous", 16), "Back"); + gtk_toolbar_insert(navigation_toolbar, chrome->back_button, -1); /* Forward button */ - gtk_toolbar_insert(navigation_toolbar, - gtk_tool_button_new( - gtk_image_new_from_icon_name("go-next", 16), - "Forward"), - -1); + chrome->forward_button = gtk_tool_button_new( + gtk_image_new_from_icon_name("go-next", 16), "Forward"); + gtk_toolbar_insert(navigation_toolbar, chrome->forward_button, -1); /* URI bar */ uri_toolitem = gtk_tool_item_new(); @@ -169,6 +165,7 @@ connect_web_view(MqTabChrome *chrome) G_CALLBACK(load_progress_cb), chrome); g_signal_connect(chrome->web_view, "notify::uri", G_CALLBACK(uri_cb), chrome); + /* FIXME: Doesn't work? */ g_signal_connect(chrome->web_view, "notify::favicon", G_CALLBACK(favicon_cb), chrome); g_signal_connect(chrome->web_view, "notify::title", diff --git a/src/tab-chrome.h b/src/tab-chrome.h index 035be40..3d08cad 100644 --- a/src/tab-chrome.h +++ b/src/tab-chrome.h @@ -30,6 +30,8 @@ typedef struct { GtkWidget *tab_label; guint tab_position; GtkWidget *container; + GtkToolItem *back_button; + GtkToolItem *forward_button; GtkWidget *uri_entry; WebKitWebView *web_view; } MqTabChrome; |