diff options
author | Allan Sandfeld Jensen <allan.jensen@theqtcompany.com> | 2015-07-08 14:06:17 +0200 |
---|---|---|
committer | Allan Sandfeld Jensen <allan.jensen@theqtcompany.com> | 2015-07-09 10:08:03 +0000 |
commit | 1d425016baf5fc1335f7f6d31b3d12c07fc37ea4 (patch) | |
tree | 08161ad975ea4e75673a8cc98b5e1d80e76d2150 | |
parent | 189299b927f76c97ec00aeff4673e3cf9e8078a5 (diff) | |
download | qtwebengine-chromium-1d425016baf5fc1335f7f6d31b3d12c07fc37ea4.tar.gz |
Export fullscreen supported preference
By disabling this preference blink will be able to tell if fullscreen
is supported before requesting it and will not show non-functional
fullscreen buttons on youtube and other HTML5 videos.
Change-Id: I2ed3828931e99295b634e6945d8ab97a1e8a34dd
Reviewed-by: Andras Becsi <andras.becsi@theqtcompany.com>
4 files changed, 8 insertions, 0 deletions
diff --git a/chromium/content/public/common/common_param_traits_macros.h b/chromium/content/public/common/common_param_traits_macros.h index c854cab30e6..37d62634149 100644 --- a/chromium/content/public/common/common_param_traits_macros.h +++ b/chromium/content/public/common/common_param_traits_macros.h @@ -223,6 +223,8 @@ IPC_STRUCT_TRAITS_BEGIN(content::WebPreferences) IPC_STRUCT_TRAITS_MEMBER(clobber_user_agent_initial_scale_quirk) IPC_STRUCT_TRAITS_MEMBER(ignore_main_frame_overflow_hidden_quirk) IPC_STRUCT_TRAITS_MEMBER(report_screen_size_in_physical_pixels_quirk) +#elif defined(TOOLKIT_QT) + IPC_STRUCT_TRAITS_MEMBER(fullscreen_supported) #endif IPC_STRUCT_TRAITS_MEMBER(default_minimum_page_scale_factor) IPC_STRUCT_TRAITS_MEMBER(default_maximum_page_scale_factor) diff --git a/chromium/content/public/common/web_preferences.cc b/chromium/content/public/common/web_preferences.cc index 1a854e065bf..c393727c289 100644 --- a/chromium/content/public/common/web_preferences.cc +++ b/chromium/content/public/common/web_preferences.cc @@ -215,6 +215,8 @@ WebPreferences::WebPreferences() clobber_user_agent_initial_scale_quirk(false), ignore_main_frame_overflow_hidden_quirk(false), report_screen_size_in_physical_pixels_quirk(false), +#elif defined(TOOLKIT_QT) + fullscreen_supported(false), #endif #if defined(OS_ANDROID) default_minimum_page_scale_factor(0.25f), diff --git a/chromium/content/public/common/web_preferences.h b/chromium/content/public/common/web_preferences.h index b07fabe4cf1..836d43605cb 100644 --- a/chromium/content/public/common/web_preferences.h +++ b/chromium/content/public/common/web_preferences.h @@ -219,6 +219,8 @@ struct CONTENT_EXPORT WebPreferences { bool clobber_user_agent_initial_scale_quirk; bool ignore_main_frame_overflow_hidden_quirk; bool report_screen_size_in_physical_pixels_quirk; +#elif defined(TOOLKIT_QT) + bool fullscreen_supported; #endif // Default (used if the page or UA doesn't override these) values for page diff --git a/chromium/content/renderer/render_view_impl.cc b/chromium/content/renderer/render_view_impl.cc index 48df2c47c64..9ef4e9fb43b 100644 --- a/chromium/content/renderer/render_view_impl.cc +++ b/chromium/content/renderer/render_view_impl.cc @@ -1109,6 +1109,8 @@ void RenderView::ApplyWebPreferences(const WebPreferences& prefs, settings->setShrinksViewportContentToFit(true); settings->setUseMobileViewportStyle(true); +#elif defined(TOOLKIT_QT) + settings->setFullscreenSupported(prefs.fullscreen_supported); #endif WebNetworkStateNotifier::setOnLine(prefs.is_online); |