Commit b762bc0d authored by Mason Freed's avatar Mason Freed Committed by Commit Bot

Remove WebComponentsV0 feature (mostly impacts WebView)

This CL removes the WebComponentsV0 feature added in [1] for
WebView. This was a temporary feature, to enable developers to
control these features starting in M86, because a Finch config
began disabling M86 Web Components for all users. Now that M86
(and M87) are out of Dev, this CL removes this feature flag
completely.

[1] https://chromium-review.googlesource.com/c/chromium/src/+/2268544

Bug: 1021631, 1021631
Change-Id: Ie6d14040105f2a239b8f95caae88a95d1da1f7b0
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2514590Reviewed-by: default avatarScott Violet <sky@chromium.org>
Reviewed-by: default avatarNate Fischer <ntfschr@chromium.org>
Reviewed-by: default avatarKinuko Yasuda <kinuko@chromium.org>
Auto-Submit: Mason Freed <masonfreed@chromium.org>
Commit-Queue: Mason Freed <masonfreed@chromium.org>
Cr-Commit-Position: refs/heads/master@{#824056}
parent 07c1ced3
......@@ -45,7 +45,6 @@ void PopulateFixedWebPreferences(WebPreferences* web_prefs) {
web_prefs->disable_features_depending_on_viz =
!::features::IsUsingVizForWebView();
web_prefs->disable_accelerated_small_canvases = true;
web_prefs->reenable_web_components_v0 = true;
// WebView has historically not adjusted font scale for text autosizing.
web_prefs->device_scale_adjustment = 1.0;
}
......
......@@ -91,9 +91,6 @@ public final class ProductionSupportedFlagList {
+ "of the total screen size. Depending on the number of WebViews and "
+ "the size of the screen this might be expensive so hidden behind a "
+ "feature flag until the true runtime cost can be measured."),
Flag.baseFeature(BlinkFeatures.WEB_COMPONENTS_V0,
"Re-enables the deprecated Web Components v0 features (Shadow DOM v0, Custom "
+ "Elements v0, and HTML Imports)."),
Flag.baseFeature(AwFeatures.WEBVIEW_DISPLAY_CUTOUT,
"Enables display cutout (notch) support in WebView for Android P and above."),
Flag.baseFeature(AwFeatures.WEBVIEW_CPU_AFFINITY_RESTRICT_TO_LITTLE_CORES,
......
......@@ -299,9 +299,6 @@ void SetRuntimeFeaturesFromChromiumFeatures() {
{wf::EnableDocumentPolicyNegotiation, features::kDocumentPolicyNegotiation},
{wf::EnableScrollUnification, features::kScrollUnification},
{wf::EnableNeverSlowMode, features::kNeverSlowMode},
{wf::EnableShadowDOMV0, blink::features::kWebComponentsV0},
{wf::EnableCustomElementsV0, blink::features::kWebComponentsV0},
{wf::EnableHTMLImports, blink::features::kWebComponentsV0},
{wf::EnableVideoPlaybackQuality, features::kVideoPlaybackQuality},
{wf::EnableBrowserVerifiedUserActivationKeyboard,
features::kBrowserVerifiedUserActivationKeyboard},
......@@ -351,7 +348,6 @@ void SetRuntimeFeaturesFromChromiumFeatures() {
blink::features::kCSSReducedFontLoadingLayoutInvalidations},
{"CSSMatchedPropertiesCacheDependencies",
blink::features::kCSSMatchedPropertiesCacheDependencies},
{"CustomElementsV0", blink::features::kWebComponentsV0},
{"FeaturePolicyForClientHints",
features::kFeaturePolicyForClientHints},
{"EditingNG", blink::features::kEditingNG},
......@@ -360,7 +356,6 @@ void SetRuntimeFeaturesFromChromiumFeatures() {
{"FontSrcLocalMatching", features::kFontSrcLocalMatching},
{"ForceSynchronousHTMLParsing",
blink::features::kForceSynchronousHTMLParsing},
{"HTMLImports", blink::features::kWebComponentsV0},
{"IgnoreCrossOriginWindowWhenNamedAccessOnWindow",
blink::features::kIgnoreCrossOriginWindowWhenNamedAccessOnWindow},
{"LangClientHintHeader", features::kLangClientHintHeader},
......@@ -376,7 +371,6 @@ void SetRuntimeFeaturesFromChromiumFeatures() {
{"ParentNodeReplaceChildren",
blink::features::kParentNodeReplaceChildren},
{"RawClipboard", blink::features::kRawClipboard},
{"ShadowDOMV0", blink::features::kWebComponentsV0},
{"StorageAccessAPI", blink::features::kStorageAccessAPI},
{"TrustedDOMTypes", features::kTrustedDOMTypes},
{"UserAgentClientHint", features::kUserAgentClientHint},
......
......@@ -306,10 +306,6 @@ const base::Feature kFontAccess{"FontAccess",
const base::Feature kFontAccessChooser{"FontAccessChooser",
base::FEATURE_DISABLED_BY_DEFAULT};
// Allows Web Components v0 to be re-enabled.
const base::Feature kWebComponentsV0{"WebComponentsV0",
base::FEATURE_DISABLED_BY_DEFAULT};
// Prefetch request properties are updated to be privacy-preserving. See
// crbug.com/988956.
const base::Feature kPrefetchPrivacyChanges{"PrefetchPrivacyChanges",
......
......@@ -185,7 +185,6 @@ WebPreferences::WebPreferences()
scroll_top_left_interop_enabled(true),
disable_features_depending_on_viz(false),
disable_accelerated_small_canvases(false),
reenable_web_components_v0(false),
#endif // defined(OS_ANDROID)
#if defined(OS_ANDROID)
default_minimum_page_scale_factor(0.25f),
......
......@@ -316,7 +316,6 @@ bool StructTraits<blink::mojom::WebPreferencesDataView,
data.disable_features_depending_on_viz();
out->disable_accelerated_small_canvases =
data.disable_accelerated_small_canvases();
out->reenable_web_components_v0 = data.reenable_web_components_v0();
#endif
out->force_dark_mode_enabled = data.force_dark_mode_enabled();
out->default_minimum_page_scale_factor =
......
......@@ -87,8 +87,6 @@ BLINK_COMMON_EXPORT extern const base::Feature kFileHandlingAPI;
BLINK_COMMON_EXPORT extern const base::Feature kAllowSyncXHRInPageDismissal;
BLINK_COMMON_EXPORT extern const base::Feature kPrefetchPrivacyChanges;
BLINK_COMMON_EXPORT extern const base::Feature kWebComponentsV0;
BLINK_COMMON_EXPORT extern const char kMixedContentAutoupgradeModeParamName[];
BLINK_COMMON_EXPORT extern const char kMixedContentAutoupgradeModeAllPassive[];
......
......@@ -255,9 +255,6 @@ struct BLINK_COMMON_EXPORT WebPreferences {
bool disable_features_depending_on_viz;
// Don't accelerate small canvases to avoid crashes TODO(crbug.com/1004304)
bool disable_accelerated_small_canvases;
// Re-enable Web Components v0 on Webview, temporarily. This should get
// removed when crbug.com/1021631 gets fixed.
bool reenable_web_components_v0;
#endif // defined(OS_ANDROID)
// Enable forcibly modifying content rendering to result in a light on dark
......
......@@ -673,11 +673,6 @@ struct BLINK_COMMON_EXPORT StructTraits<blink::mojom::WebPreferencesDataView,
const blink::web_pref::WebPreferences& r) {
return r.disable_accelerated_small_canvases;
}
static bool reenable_web_components_v0(
const blink::web_pref::WebPreferences& r) {
return r.reenable_web_components_v0;
}
#endif
static bool force_dark_mode_enabled(
......
......@@ -349,11 +349,6 @@ struct WebPreferences {
// Don't accelerate small canvases to avoid crashes TODO(crbug.com/1004304)
bool disable_accelerated_small_canvases;
// Re-enable Web Components v0 on Webview, temporarily. This should get
// removed when crbug.com/1021631 gets fixed.
[EnableIf=is_android]
bool reenable_web_components_v0;
// Enable forcibly modifying content rendering to result in a light on dark
// color scheme.
bool force_dark_mode_enabled;
......
......@@ -2120,11 +2120,6 @@ void WebView::ApplyWebPreferences(const web_pref::WebPreferences& prefs,
!prefs.disable_features_depending_on_viz);
WebRuntimeFeatures::EnableAcceleratedSmallCanvases(
!prefs.disable_accelerated_small_canvases);
if (prefs.reenable_web_components_v0) {
WebRuntimeFeatures::EnableShadowDOMV0(true);
WebRuntimeFeatures::EnableCustomElementsV0(true);
WebRuntimeFeatures::EnableHTMLImports(true);
}
#endif // defined(OS_ANDROID)
settings->SetForceDarkModeEnabled(prefs.force_dark_mode_enabled);
......
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