Index: third_party/WebKit/Source/core/html/shadow/MediaControls.cpp |
diff --git a/third_party/WebKit/Source/core/html/shadow/MediaControls.cpp b/third_party/WebKit/Source/core/html/shadow/MediaControls.cpp |
index 89f8b67ed7531bd47f8619d88d91b4e59aeef7df..2b588022bc6edd2c7194dd234636de34aff6b0f0 100644 |
--- a/third_party/WebKit/Source/core/html/shadow/MediaControls.cpp |
+++ b/third_party/WebKit/Source/core/html/shadow/MediaControls.cpp |
@@ -67,12 +67,20 @@ static bool shouldShowFullscreenButton(const HTMLMediaElement& mediaElement) { |
if (!Fullscreen::fullscreenEnabled(mediaElement.document())) |
return false; |
+ if (mediaElement.controlsList()->tokens().contains("nofullscreen")) |
+ return false; |
+ |
return true; |
} |
static bool shouldShowCastButton(HTMLMediaElement& mediaElement) { |
- return !mediaElement.fastHasAttribute(HTMLNames::disableremoteplaybackAttr) && |
- mediaElement.hasRemoteRoutes(); |
+ if (mediaElement.fastHasAttribute(HTMLNames::disableremoteplaybackAttr)) |
+ return false; |
+ |
+ if (mediaElement.controlsList()->tokens().contains("noremoteplayback")) |
+ return false; |
+ |
+ return mediaElement.hasRemoteRoutes(); |
} |
static bool preferHiddenVolumeControls(const Document& document) { |