[epiphany/gnome-3-28] Create sync web context using Epiphany website data manager



commit 240fd3e1c39661d52b3a4872bb0f2151d7a210ce
Author: Michael Catanzaro <mcatanzaro igalia com>
Date:   Fri Aug 31 17:32:41 2018 -0500

    Create sync web context using Epiphany website data manager
    
    I was confused why ~/.local/share/webkitgtk was being created in Ephy
    Tech Preview, until I realized the only storage was being used for
    accounts.firefox.com. Let's save this data under Epiphany's proper
    cache and data directories.

 src/prefs-dialog.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
---
diff --git a/src/prefs-dialog.c b/src/prefs-dialog.c
index 1af522c97..c2fdaa598 100644
--- a/src/prefs-dialog.c
+++ b/src/prefs-dialog.c
@@ -530,6 +530,7 @@ static void
 sync_setup_firefox_iframe (PrefsDialog *dialog)
 {
   EphyEmbedShell *shell;
+  WebKitWebsiteDataManager *manager;
   WebKitWebContext *embed_context;
   WebKitWebContext *sync_context;
   const char *script;
@@ -555,7 +556,8 @@ sync_setup_firefox_iframe (PrefsDialog *dialog)
 
     shell = ephy_embed_shell_get_default ();
     embed_context = ephy_embed_shell_get_web_context (shell);
-    sync_context = webkit_web_context_new ();
+    manager = webkit_web_context_get_website_data_manager (embed_context);
+    sync_context = webkit_web_context_new_with_website_data_manager (manager);
     webkit_web_context_set_preferred_languages (sync_context,
                                                 g_object_get_data (G_OBJECT (embed_context), 
"preferred-languages"));
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]