summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPatrick McDermott <pj@pehjota.net>2017-10-30 13:44:21 (EDT)
committer Patrick McDermott <pj@pehjota.net>2017-10-30 13:44:21 (EDT)
commitf4c0ac4db259925a875ab36a2bdd7c22838514ba (patch)
tree22683d4365cec5b8cf92da06d97c794034e90477
parent4a1b1a7025f4dde3dfb58a76b7fc1d7fffc0cdd4 (diff)
downloadmarquee-f4c0ac4db259925a875ab36a2bdd7c22838514ba.zip
marquee-f4c0ac4db259925a875ab36a2bdd7c22838514ba.tar.gz
marquee-f4c0ac4db259925a875ab36a2bdd7c22838514ba.tar.bz2
MqWebView: mq_web_view_scheme_set_methods() on URI change
Not in constructed() method.
-rw-r--r--src/web-view.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/web-view.c b/src/web-view.c
index 8e75eba..f688cf5 100644
--- a/src/web-view.c
+++ b/src/web-view.c
@@ -79,6 +79,9 @@ uri_cb(MqWebView *web_view, GParamSpec G_GNUC_UNUSED *param_spec)
uri = webkit_web_view_get_uri(WEBKIT_WEB_VIEW(web_view));
+ mq_web_view_scheme_set_methods(&web_view->scheme_methods,
+ &web_view->scheme, uri);
+
web_view->uri = web_view->scheme_methods->display_uri(
web_view, &web_view->scheme, uri);
@@ -195,9 +198,6 @@ constructed(GObject *object)
web_view = MQ_WEB_VIEW(object);
- mq_web_view_scheme_set_methods(&web_view->scheme_methods,
- &web_view->scheme, web_view->uri);
-
web_view->config = mq_application_get_config(
mq_tab_page_get_application(web_view->tab_page));
@@ -375,6 +375,9 @@ mq_web_view_load_uri(MqWebView *web_view, const gchar *uri)
{
gchar *rw_uri;
+ mq_web_view_scheme_set_methods(&web_view->scheme_methods,
+ &web_view->scheme, uri);
+
if (!uri) {
/* Happens during object construction. */
return;