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

Unified Diff: Source/web/ContextMenuClientImpl.cpp

Issue 182613006: Remove media controls when not in use. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Add shouldDisplayControls and fix overlay logic Created 6 years, 10 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/web/ContextMenuClientImpl.cpp
diff --git a/Source/web/ContextMenuClientImpl.cpp b/Source/web/ContextMenuClientImpl.cpp
index 8f16ffa83ec1e189f9df7a13b6ce4d83b9a96e69..52c59f9dcfa02f9b3f52c27e748b74b081b63cad 100644
--- a/Source/web/ContextMenuClientImpl.cpp
+++ b/Source/web/ContextMenuClientImpl.cpp
@@ -243,7 +243,7 @@ void ContextMenuClientImpl::showContextMenu(const WebCore::ContextMenu* defaultM
data.mediaFlags |= WebContextMenuData::MediaHasAudio;
if (mediaElement->hasVideo())
data.mediaFlags |= WebContextMenuData::MediaHasVideo;
- if (mediaElement->controls())
+ if (mediaElement->shouldDisplayControls())
data.mediaFlags |= WebContextMenuData::MediaControls;
} else if (r.innerNonSharedNode()->hasTagName(HTMLNames::objectTag)
|| r.innerNonSharedNode()->hasTagName(HTMLNames::embedTag)) {
« Source/core/html/HTMLMediaElement.cpp ('K') | « Source/core/html/HTMLMediaElement.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698