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

Unified Diff: chrome/browser/chrome_content_browser_client.cc

Issue 1906533002: Add 'autoplay' content settings and expose it to Blink. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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: chrome/browser/chrome_content_browser_client.cc
diff --git a/chrome/browser/chrome_content_browser_client.cc b/chrome/browser/chrome_content_browser_client.cc
index 2a8495aa37f96841351f0e02190f21ef21e084de..0b8c4d4158ef995506ae5c93a068cea97522482b 100644
--- a/chrome/browser/chrome_content_browser_client.cc
+++ b/chrome/browser/chrome_content_browser_client.cc
@@ -656,7 +656,7 @@ float GetDeviceScaleAdjustment() {
#endif // defined(OS_ANDROID)
#if defined(ENABLE_EXTENSIONS)
-// By default, JavaScript and images are enabled in guest content.
+// By default, JavaScript, images and autoplay are enabled in guest content.
void GetGuestViewDefaultContentSettingRules(
bool incognito,
RendererContentSettingRules* rules) {
@@ -673,6 +673,12 @@ void GetGuestViewDefaultContentSettingRules(
CONTENT_SETTING_ALLOW,
std::string(),
incognito));
+ rules->autoplay_rules.push_back(
+ ContentSettingPatternSource(ContentSettingsPattern::Wildcard(),
+ ContentSettingsPattern::Wildcard(),
+ CONTENT_SETTING_ALLOW,
+ std::string(),
+ incognito));
}
#endif // defined(ENABLE_EXTENSIONS)

Powered by Google App Engine
This is Rietveld 408576698