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

Unified Diff: Source/core/html/shadow/MediaControlElements.cpp

Issue 363563007: Only show overlay play button when controls are enabled. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@shouldShowControls
Patch Set: Extended test coverage Created 6 years, 6 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: Source/core/html/shadow/MediaControlElements.cpp
diff --git a/Source/core/html/shadow/MediaControlElements.cpp b/Source/core/html/shadow/MediaControlElements.cpp
index ace36c0e693a9656d29c098c85d337f4e7aa6c9b..c463fc10e58d1acd3829e886494907fbb0216bb2 100644
--- a/Source/core/html/shadow/MediaControlElements.cpp
+++ b/Source/core/html/shadow/MediaControlElements.cpp
@@ -283,7 +283,7 @@ void MediaControlOverlayPlayButtonElement::defaultEventHandler(Event* event)
void MediaControlOverlayPlayButtonElement::updateDisplayType()
{
- if (mediaElement().togglePlayStateWillPlay()) {
+ if (mediaElement().shouldShowControls() && mediaElement().togglePlayStateWillPlay()) {
show();
} else
hide();
« no previous file with comments | « LayoutTests/media/video-controls-overlay-play-button-expected.txt ('k') | Source/core/html/shadow/MediaControls.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698