[epiphany] embed: Use a custom local storage directory for epiphany
- From: Carlos Garcia Campos <carlosgc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [epiphany] embed: Use a custom local storage directory for epiphany
- Date: Tue, 25 Nov 2014 13:27:28 +0000 (UTC)
commit b4c12fa62175f7826f0ded862807f52a58aeff8b
Author: Carlos Garcia Campos <cgarcia igalia com>
Date: Mon Nov 24 11:20:26 2014 +0100
embed: Use a custom local storage directory for epiphany
Instead of using the default path. This ensures private profiles don't
leave data in the user home directory.
https://bugzilla.gnome.org/show_bug.cgi?id=738720
embed/ephy-embed-shell.c | 8 +++++++-
1 files changed, 7 insertions(+), 1 deletions(-)
---
diff --git a/embed/ephy-embed-shell.c b/embed/ephy-embed-shell.c
index 1057733..b041957 100644
--- a/embed/ephy-embed-shell.c
+++ b/embed/ephy-embed-shell.c
@@ -586,7 +586,13 @@ ephy_embed_shell_startup (GApplication* application)
G_APPLICATION_CLASS (ephy_embed_shell_parent_class)->startup (application);
/* We're not remoting, setup the Web Context. */
- priv->web_context = webkit_web_context_new ();
+
+ /* Local Storage */
+ local_storage_path = g_build_filename (EPHY_EMBED_SHELL_MODE_HAS_PRIVATE_PROFILE (priv->mode) ?
+ ephy_dot_dir () : g_get_user_data_dir (),
+ g_get_prgname (), "localstorage", NULL);
+ priv->web_context = g_object_new (WEBKIT_TYPE_WEB_CONTEXT, "local-storage-directory", local_storage_path,
NULL);
+ g_free (local_storage_path);
ephy_embed_shell_setup_web_extensions_connection (shell);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]