From eaf6e205924ebf5b20267cfa37c6cf0efad44eda Mon Sep 17 00:00:00 2001 From: Florian Bruhin Date: Wed, 17 May 2017 10:02:42 +0200 Subject: Don't disable local storage for offTheRecord profiles Chromium has local storage enabled in icognito windows, and simply doesn't persist it to disk. QtWebEngine seems to do the same when local storage is enabled in an off-the-record profile, so there's no reason to disable it by default. This also matches the behavior in Chromium (and Firefox, but not Safari). [ChangeLog] HTML 5 local storage is now enabled by default (but residing in memory) in off-the-record profiles. Change-Id: I0cb7e946575a53471ffed9d3324b3ae4c2e80eee Reviewed-by: Allan Sandfeld Jensen --- src/core/web_engine_settings.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'src/core/web_engine_settings.cpp') diff --git a/src/core/web_engine_settings.cpp b/src/core/web_engine_settings.cpp index 4231389e6..4be985e0c 100644 --- a/src/core/web_engine_settings.cpp +++ b/src/core/web_engine_settings.cpp @@ -204,7 +204,7 @@ QString WebEngineSettings::defaultTextEncoding() const return m_defaultEncoding.isEmpty()? parentSettings->defaultTextEncoding() : m_defaultEncoding; } -void WebEngineSettings::initDefaults(bool offTheRecord) +void WebEngineSettings::initDefaults() { if (s_defaultAttributes.isEmpty()) { // Initialize the default settings. @@ -245,8 +245,6 @@ void WebEngineSettings::initDefaults(bool offTheRecord) s_defaultAttributes.insert(AllowGeolocationOnInsecureOrigins, false); s_defaultAttributes.insert(AllowWindowActivationFromJavaScript, false); } - if (offTheRecord) - m_attributes.insert(LocalStorageEnabled, false); if (s_defaultFontFamilies.isEmpty()) { // Default fonts -- cgit v1.2.3