aboutsummaryrefslogtreecommitdiffstats
path: root/embed/ephy-embed-single.c
diff options
context:
space:
mode:
authorCarlos Garcia Campos <cgarcia@igalia.com>2012-06-08 16:50:30 +0800
committerCarlos Garcia Campos <carlosgc@gnome.org>2012-07-04 19:15:37 +0800
commitdcb11d1f5517bd4df39fc0d0228fd02214ad903d (patch)
tree48cace962d9e6edafed409ec5720769d22702545 /embed/ephy-embed-single.c
parent74ff5812f0cc1c2f94c64cc00bc99e8bc887793f (diff)
downloadgsoc2013-epiphany-dcb11d1f5517bd4df39fc0d0228fd02214ad903d.tar.gz
gsoc2013-epiphany-dcb11d1f5517bd4df39fc0d0228fd02214ad903d.tar.zst
gsoc2013-epiphany-dcb11d1f5517bd4df39fc0d0228fd02214ad903d.zip
Port cookies to WebKit2
https://bugzilla.gnome.org/show_bug.cgi?id=678626
Diffstat (limited to 'embed/ephy-embed-single.c')
-rw-r--r--embed/ephy-embed-single.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/embed/ephy-embed-single.c b/embed/ephy-embed-single.c
index c927ba89c..da4704206 100644
--- a/embed/ephy-embed-single.c
+++ b/embed/ephy-embed-single.c
@@ -405,8 +405,20 @@ gboolean
ephy_embed_single_initialize (EphyEmbedSingle *single)
{
#ifdef HAVE_WEBKIT2
+ WebKitWebContext *web_context;
+ char *cookie_policy;
+
/* TODO: Network features */
- webkit_web_context_register_uri_scheme (webkit_web_context_get_default (),
+
+ web_context = webkit_web_context_get_default ();
+
+ cookie_policy = g_settings_get_string (EPHY_SETTINGS_WEB,
+ EPHY_PREFS_WEB_COOKIES_POLICY);
+ ephy_embed_prefs_set_cookie_accept_policy (webkit_web_context_get_cookie_manager (web_context),
+ cookie_policy);
+ g_free (cookie_policy);
+
+ webkit_web_context_register_uri_scheme (web_context,
EPHY_ABOUT_SCHEME,
about_request_cb,
NULL);