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

Unified Diff: third_party/WebKit/Source/core/html/AutoplayExperimentHelper.h

Issue 1853543002: Add -ifsameorigin to autoplay experiment. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@autoplay
Patch Set: comment. 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: third_party/WebKit/Source/core/html/AutoplayExperimentHelper.h
diff --git a/third_party/WebKit/Source/core/html/AutoplayExperimentHelper.h b/third_party/WebKit/Source/core/html/AutoplayExperimentHelper.h
index 890ee365413ab35a9c84b85443d6548aa9953af0..ea7a3ed99e5c0cd3e0041999a27df6aaaec74161 100644
--- a/third_party/WebKit/Source/core/html/AutoplayExperimentHelper.h
+++ b/third_party/WebKit/Source/core/html/AutoplayExperimentHelper.h
@@ -124,6 +124,9 @@ public:
virtual PageVisibilityState pageVisibilityState() const = 0;
virtual String autoplayExperimentMode() const = 0;
+ // Frame
+ virtual bool isCrossOrigin() const = 0;
+
// LayoutObject
virtual void setRequestPositionUpdates(bool) = 0;
virtual IntRect absoluteBoundingBoxRect() const = 0;
@@ -182,9 +185,12 @@ public:
// Restrict gestureless autoplay to sites which contain the
// viewport tag.
IfMobile = 1 << 6,
+ // Restrict gestureless autoplay to sites which are from the same origin
+ // as the top-level frame.
+ IfSameOrigin = 1 << 7,
// If gestureless autoplay is allowed, then mute the media before
// starting to play.
- PlayMuted = 1 << 7,
+ PlayMuted = 1 << 8,
};
DEFINE_INLINE_TRACE() { visitor->trace(m_client); }

Powered by Google App Engine
This is Rietveld 408576698