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: LayoutTests/media/controls-cast-do-not-fade-out.html

Issue 650893002: [Cast] Disable autohide of media controls for remote playback (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Added LayoutTest Created 6 years, 2 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: LayoutTests/media/controls-cast-do-not-fade-out.html
diff --git a/LayoutTests/media/controls-cast-do-not-fade-out.html b/LayoutTests/media/controls-cast-do-not-fade-out.html
new file mode 100644
index 0000000000000000000000000000000000000000..7c799f8f1134d02b87381a9b6dafbaa58ff163bd
--- /dev/null
+++ b/LayoutTests/media/controls-cast-do-not-fade-out.html
@@ -0,0 +1,55 @@
+<!doctype html>
+<html>
+ <head>
+ <title>This tests that controls do not fade out when the video is playing remotely.</title>
+ <script src="../resources/testharness.js"></script>
+ <script src="../resources/testharnessreport.js"></script>
+ <script src="media-file.js"></script>
+ <script src="media-controls.js"></script>
+ <script src="video-test.js"></script>
+ </head>
+ <body>
+ <video controls></video>
+ <script>
+ var controls;
+ var test;
+
+ function playing()
+ {
+ internals.mediaPlayerPlayingRemotelyChanged(video, true);
+ runAfterHideMediaControlsTimerFired(function()
+ {
+ controls = mediaControlsButton(video, "panel");
+ testExpected("getComputedStyle(controls).opacity", 1);
+
+ consoleWrite("");
+
+ internals.mediaPlayerPlayingRemotelyChanged(video, false);
+ runAfterHideMediaControlsTimerFired(function()
+ {
+ testExpected("getComputedStyle(controls).opacity", 0);
+
+ consoleWrite("");
+
+ test.done();
+ },
+ video);
+ }, video);
+ }
+
+ function loadedmetadata()
+ {
+ video.addEventListener("playing", playing);
+ video.play();
+ }
+
+ async_test(function(t)
+ {
+ test = t;
+ findMediaElement();
+ video.src = findMediaFile("video", "content/test");
+ video.addEventListener("loadedmetadata", loadedmetadata);
Peter Beverloo 2014/10/13 16:37:24 Can we just bind to the |playing| event here, call
whywhat 2014/10/13 16:56:28 Done.
+ });
+ </script>
+ </body>
+</html>
« no previous file with comments | « no previous file | LayoutTests/media/controls-cast-do-not-fade-out-expected.txt » ('j') | Source/core/testing/Internals.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698