Commit 028d7f35 authored by Xida Chen's avatar Xida Chen Committed by Commit Bot

Add a runtime enabled feature flag for raster-inducing scroll

In order to make sure that nothing breaks during our implementation of
raster-inducing scroll, we should just hide this new feature behind a
flag.

Bug: 820048
Change-Id: I38b446cff82aa5f4c9e23b5fdb04f5895d218e2a
Reviewed-on: https://chromium-review.googlesource.com/955666Reviewed-by: default avatarKentaro Hara <haraken@chromium.org>
Reviewed-by: default avatarDmitry Gozman <dgozman@chromium.org>
Commit-Queue: Xida Chen <xidachen@chromium.org>
Cr-Commit-Position: refs/heads/master@{#541842}
parent 41347824
......@@ -338,6 +338,9 @@ void SetRuntimeFeaturesDefaultsAndUpdateFromArgs(
false);
}
if (base::FeatureList::IsEnabled(features::kRasterInducingScroll))
WebRuntimeFeatures::EnableRasterInducingScroll(true);
WebRuntimeFeatures::EnableFeatureFromString(
"AllowContentInitiatedDataUrlNavigations",
base::FeatureList::IsEnabled(
......
......@@ -286,6 +286,10 @@ const base::Feature kPurgeAndSuspend {
const base::Feature kPWAFullCodeCache{"PWAFullCodeCache",
base::FEATURE_DISABLED_BY_DEFAULT};
// Enable raster-inducing scroll.
const base::Feature kRasterInducingScroll{"RasterInducingScroll",
base::FEATURE_DISABLED_BY_DEFAULT};
// Throttle Blink's rendering pipeline based on frame visibility.
const base::Feature kRenderingPipelineThrottling{
"RenderingPipelineThrottling", base::FEATURE_ENABLED_BY_DEFAULT};
......
......@@ -70,6 +70,7 @@ CONTENT_EXPORT extern const base::Feature kPassiveEventListenersDueToFling;
CONTENT_EXPORT extern const base::Feature kPepper3DImageChromium;
CONTENT_EXPORT extern const base::Feature kPurgeAndSuspend;
CONTENT_EXPORT extern const base::Feature kPWAFullCodeCache;
CONTENT_EXPORT extern const base::Feature kRasterInducingScroll;
CONTENT_EXPORT extern const base::Feature kRenderingPipelineThrottling;
CONTENT_EXPORT extern const base::Feature kReportRendererPeakMemoryStats;
CONTENT_EXPORT extern const base::Feature kRequireCSSExtensionForFile;
......
......@@ -260,6 +260,10 @@ void WebRuntimeFeatures::EnablePreloadDefaultIsMetadata(bool enable) {
RuntimeEnabledFeatures::SetPreloadDefaultIsMetadataEnabled(enable);
}
void WebRuntimeFeatures::EnableRasterInducingScroll(bool enable) {
RuntimeEnabledFeatures::SetRasterInducingScrollEnabled(enable);
}
void WebRuntimeFeatures::EnableScriptedSpeech(bool enable) {
RuntimeEnabledFeatures::SetScriptedSpeechEnabled(enable);
}
......
......@@ -880,6 +880,10 @@
{
name: "PWAFullCodeCache"
},
{
name: "RasterInducingScroll",
status: "experimental",
},
{
name: "ReducedReferrerGranularity",
},
......
......@@ -118,6 +118,7 @@ class WebRuntimeFeatures {
BLINK_PLATFORM_EXPORT static void EnablePrintBrowser(bool);
BLINK_PLATFORM_EXPORT static void EnablePresentationAPI(bool);
BLINK_PLATFORM_EXPORT static void EnablePushMessaging(bool);
BLINK_PLATFORM_EXPORT static void EnableRasterInducingScroll(bool);
BLINK_PLATFORM_EXPORT static void EnableReducedReferrerGranularity(bool);
BLINK_PLATFORM_EXPORT static void EnableRemotePlaybackAPI(bool);
BLINK_PLATFORM_EXPORT static void EnableRenderingPipelineThrottling(bool);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment