diff options
author | Patrick McDermott <pj@pehjota.net> | 2017-09-29 04:19:03 (EDT) |
---|---|---|
committer | Patrick McDermott <pj@pehjota.net> | 2017-09-29 04:35:27 (EDT) |
commit | 3c0f92a0fddfc9c3d8d30c83e010073db1fdb22c (patch) | |
tree | 1f996fc32d8c2b65afc7097ca517f5481eaa080a | |
parent | ea74a3c92a9f7abb2ffbf2aeeeeaeb8921d61e46 (diff) | |
download | marquee-3c0f92a0fddfc9c3d8d30c83e010073db1fdb22c.zip marquee-3c0f92a0fddfc9c3d8d30c83e010073db1fdb22c.tar.gz marquee-3c0f92a0fddfc9c3d8d30c83e010073db1fdb22c.tar.bz2 |
mq_application_new(): Register "mq-about" URI scheme
-rw-r--r-- | src/application.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/src/application.c b/src/application.c index 531eb53..9ae8448 100644 --- a/src/application.c +++ b/src/application.c @@ -25,19 +25,24 @@ #include <webkit2/webkit2.h> #include "application.h" +#include "about.h" #include "window.h" MqApplication * mq_application_new(gchar __attribute__((unused)) *profile, gboolean __attribute__((unused)) private) { - MqApplication *application; + MqApplication *application; + WebKitWebContext *web_context; application = malloc(sizeof(*application)); application->windows = NULL; - webkit_web_context_set_favicon_database_directory( - webkit_web_context_get_default(), NULL); + web_context = webkit_web_context_get_default(); + webkit_web_context_set_favicon_database_directory(web_context, NULL); + webkit_web_context_register_uri_scheme(web_context, "mq-about", + (WebKitURISchemeRequestCallback) mq_about_request, application, + NULL); return application; } |