diff options
author | Allan Sandfeld Jensen <allan.jensen@theqtcompany.com> | 2016-08-30 12:46:45 +0200 |
---|---|---|
committer | Allan Sandfeld Jensen <allan.jensen@theqtcompany.com> | 2016-08-30 12:47:20 +0200 |
commit | da6f33c8929bf122e7cdec5617d89c59d03e3632 (patch) | |
tree | 9d90d90a3e7cdd6fbca8d40b54a45e90877677e4 /src/core/web_engine_settings.cpp | |
parent | 9cda8d4384825bd93b949f31953548beda165ef8 (diff) | |
parent | 327c9b9e0c68550e474d9ffdc21ece6324b5e7a1 (diff) |
Merge remote-tracking branch 'origin/5.7' into 5.8
Change-Id: I82f7a6a6d1bf27dc8adf7e2a91ea8ab29c54a607
Diffstat (limited to 'src/core/web_engine_settings.cpp')
-rw-r--r-- | src/core/web_engine_settings.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/core/web_engine_settings.cpp b/src/core/web_engine_settings.cpp index 754fa2f51..8e284c9d6 100644 --- a/src/core/web_engine_settings.cpp +++ b/src/core/web_engine_settings.cpp @@ -44,6 +44,7 @@ #include "type_conversion.h" #include "base/command_line.h" +#include "chrome/common/chrome_switches.h" #include "content/browser/gpu/gpu_process_host.h" #include "content/public/common/content_switches.h" #include "content/public/common/web_preferences.h" @@ -232,6 +233,7 @@ void WebEngineSettings::initDefaults(bool offTheRecord) !commandLine->HasSwitch(switches::kDisableExperimentalWebGL); bool accelerated2dCanvas = content::GpuProcessHost::gpu_enabled() && !commandLine->HasSwitch(switches::kDisableAccelerated2dCanvas); + bool allowRunningInsecureContent = commandLine->HasSwitch(switches::kAllowRunningInsecureContent); s_defaultAttributes.insert(ScrollAnimatorEnabled, smoothScrolling); s_defaultAttributes.insert(WebGLEnabled, webGL); s_defaultAttributes.insert(Accelerated2dCanvasEnabled, accelerated2dCanvas); @@ -239,6 +241,7 @@ void WebEngineSettings::initDefaults(bool offTheRecord) s_defaultAttributes.insert(TouchIconsEnabled, false); s_defaultAttributes.insert(FocusOnNavigationEnabled, true); s_defaultAttributes.insert(PrintElementBackgrounds, true); + s_defaultAttributes.insert(AllowRunningInsecureContent, allowRunningInsecureContent); } if (offTheRecord) m_attributes.insert(LocalStorageEnabled, false); @@ -315,6 +318,7 @@ void WebEngineSettings::applySettingsToWebPreferences(content::WebPreferences *p prefs->accelerated_2d_canvas_enabled = testAttribute(Accelerated2dCanvasEnabled); prefs->experimental_webgl_enabled = testAttribute(WebGLEnabled); prefs->should_print_backgrounds = testAttribute(PrintElementBackgrounds); + prefs->allow_running_insecure_content = testAttribute(AllowRunningInsecureContent); // Fonts settings. prefs->standard_font_family_map[content::kCommonScript] = toString16(fontFamily(StandardFont)); |