Commit 9e4a047a authored by Rodney Ding's avatar Rodney Ding Committed by Commit Bot

Add chromium and blink flags for never-slow-mode.

- This is the first step in implementing never-slow-mode in chrome.
- Both flags are disabled by default.
- Blink runtime flag will use the chromium feature state.

Bug: 892672
Change-Id: I2098e435628219ffe5a798d485d73e1e0c590bc7
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1864331Reviewed-by: default avatarJason Chase <chasej@chromium.org>
Reviewed-by: default avatarKentaro Hara <haraken@chromium.org>
Reviewed-by: default avatarMatt Falkenhagen <falken@chromium.org>
Commit-Queue: Rodney Ding <rodneyding@google.com>
Cr-Commit-Position: refs/heads/master@{#707482}
parent ad4338ea
......@@ -310,6 +310,8 @@ void SetRuntimeFeaturesFromChromiumFeatures() {
kEnableOnly},
{wf::EnableDocumentPolicy, features::kDocumentPolicy,
kUseFeatureState},
{wf::EnableNeverSlowMode, features::kNeverSlowMode,
kUseFeatureState},
};
for (const auto& mapping : blinkFeatureToBaseFeatureMapping) {
const bool featureEnabled =
......
......@@ -318,6 +318,9 @@ const base::Feature kNetworkServiceInProcess {
#endif
};
const base::Feature kNeverSlowMode{"NeverSlowMode",
base::FEATURE_DISABLED_BY_DEFAULT};
// Kill switch for Web Notification content images.
const base::Feature kNotificationContentImage{"NotificationContentImage",
base::FEATURE_ENABLED_BY_DEFAULT};
......
......@@ -75,6 +75,7 @@ CONTENT_EXPORT extern const base::Feature kMouseSubframeNoImplicitCapture;
CONTENT_EXPORT extern const base::Feature kNavigationImmediateResponseBody;
CONTENT_EXPORT extern const base::Feature kNetworkQualityEstimatorWebHoldback;
CONTENT_EXPORT extern const base::Feature kNetworkServiceInProcess;
CONTENT_EXPORT extern const base::Feature kNeverSlowMode;
CONTENT_EXPORT extern const base::Feature kNotificationContentImage;
CONTENT_EXPORT extern const base::Feature kNotificationTriggers;
CONTENT_EXPORT extern const base::Feature kOriginPolicy;
......
......@@ -127,6 +127,7 @@ class WebRuntimeFeatures {
bool);
BLINK_PLATFORM_EXPORT static void EnableNavigatorContentUtils(bool);
BLINK_PLATFORM_EXPORT static void EnableNetInfoDownlinkMax(bool);
BLINK_PLATFORM_EXPORT static void EnableNeverSlowMode(bool);
BLINK_PLATFORM_EXPORT static void EnableUpdateHoverAtBeginFrame(bool);
BLINK_PLATFORM_EXPORT static void EnableNotificationConstructor(bool);
BLINK_PLATFORM_EXPORT static void EnableNotificationContentImage(bool);
......
......@@ -292,6 +292,10 @@ void WebRuntimeFeatures::EnableNetInfoDownlinkMax(bool enable) {
RuntimeEnabledFeatures::SetNetInfoDownlinkMaxEnabled(enable);
}
void WebRuntimeFeatures::EnableNeverSlowMode(bool enable) {
RuntimeEnabledFeatures::SetNeverSlowModeEnabled(enable);
}
void WebRuntimeFeatures::EnableOnDeviceChange(bool enable) {
RuntimeEnabledFeatures::SetOnDeviceChangeEnabled(enable);
}
......
......@@ -1083,6 +1083,9 @@
// Only Android, ChromeOS support NetInfo downlinkMax, type and ontypechange now
status: {"Android": "stable", "ChromeOS": "stable"},
},
{
name: "NeverSlowMode",
},
// Not a web exposed feature, enabled from the command line.
{
name: "NewRemotePlaybackPipeline",
......
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