summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPatrick McDermott <pj@pehjota.net>2017-10-12 12:53:00 (EDT)
committer Patrick McDermott <pj@pehjota.net>2017-10-12 12:53:00 (EDT)
commita8ec2a404a8fdec019b72b46445fbc119432de15 (patch)
tree6f52fde6545c1c5bda0c7a828b522e92d39bcc1e
parent897a1b9db90c68d0621be182823c413071e0062c (diff)
downloadmarquee-a8ec2a404a8fdec019b72b46445fbc119432de15.zip
marquee-a8ec2a404a8fdec019b72b46445fbc119432de15.tar.gz
marquee-a8ec2a404a8fdec019b72b46445fbc119432de15.tar.bz2
MqTabChrome: Set up find toolbar when Web view is set
This makes the find toolbar code a little more self-contained.
-rw-r--r--src/tab-chrome.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/tab-chrome.c b/src/tab-chrome.c
index 92acd63..f4d666c 100644
--- a/src/tab-chrome.c
+++ b/src/tab-chrome.c
@@ -740,6 +740,8 @@ find_toolbar_new(MqTabChrome *chrome)
chrome->find_match_case = FALSE;
chrome->find_searching = FALSE;
+ chrome->find_controller = webkit_web_view_get_find_controller(
+ WEBKIT_WEB_VIEW(chrome->web_view));
return chrome->find_revealer;
}
@@ -756,8 +758,6 @@ mq_tab_chrome_new(MqTab *tab, const gchar *uri)
chrome->container = gtk_box_new(GTK_ORIENTATION_VERTICAL, 0);
gtk_box_pack_start(GTK_BOX(chrome->container),
navigation_toolbar_new(chrome, uri), FALSE, FALSE, 0);
- gtk_box_pack_start(GTK_BOX(chrome->container),
- find_toolbar_new(chrome), FALSE, FALSE, 0);
return chrome;
}
@@ -983,7 +983,7 @@ void
mq_tab_chrome_set_web_view(MqTabChrome *chrome, MqWebView *web_view)
{
chrome->web_view = web_view;
- chrome->find_controller = webkit_web_view_get_find_controller(
- WEBKIT_WEB_VIEW(web_view));
+ gtk_box_pack_start(GTK_BOX(chrome->container),
+ find_toolbar_new(chrome), FALSE, FALSE, 0);
connect_web_view(chrome);
}