Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(117)

Unified Diff: content/child/runtime_features.cc

Issue 2846623003: Make autoplay policies no longer platform dependant. (Closed)
Patch Set: fix webview Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/child/runtime_features.cc
diff --git a/content/child/runtime_features.cc b/content/child/runtime_features.cc
index 10adbf550de0c8a50bcb68a25d8ce612a4c8d048..17f8094b1b0b4333afa797bc65132c2cfc96d5a6 100644
--- a/content/child/runtime_features.cc
+++ b/content/child/runtime_features.cc
@@ -371,12 +371,10 @@ void SetRuntimeFeaturesDefaultsAndUpdateFromArgs(
if (base::FeatureList::IsEnabled(features::kIdleTimeSpellChecking))
WebRuntimeFeatures::EnableFeatureFromString("IdleTimeSpellChecking", true);
-#if !defined(OS_ANDROID)
- if (command_line.GetSwitchValueASCII(switches::kAutoplayPolicy) ==
- switches::autoplay::kCrossOriginUserGestureRequiredPolicy) {
+ if (media::GetEffectiveAutoplayPolicy(command_line) !=
+ switches::autoplay::kNoUserGestureRequiredPolicy) {
WebRuntimeFeatures::EnableAutoplayMutedVideos(true);
}
-#endif
WebRuntimeFeatures::EnableLocationHardReload(
base::FeatureList::IsEnabled(features::kLocationHardReload));

Powered by Google App Engine
This is Rietveld 408576698