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

Side by Side Diff: LayoutTests/media/controls-volume-slider.html

Issue 1156993013: New media playback UI. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: manual rebaseline. Created 5 years, 5 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 unified diff | Download patch
OLDNEW
1 <!doctype html> 1 <!doctype html>
2 <html> 2 <html>
3 <head> 3 <head>
4 <title>media controls volume slider</title> 4 <title>media controls volume slider</title>
5 <script src="media-file.js"></script> 5 <script src="media-file.js"></script>
6 <script src="media-controls.js"></script> 6 <script src="media-controls.js"></script>
7 <script src="video-test.js"></script> 7 <script src="video-test.js"></script>
8 </head> 8 </head>
9 <body> 9 <body>
10 <audio controls></audio> 10 <audio controls></audio>
11 <script> 11 <script>
12 findMediaElement(); 12 findMediaElement();
13 audio.src = findMediaFile("audio", "content/test"); 13 audio.src = findMediaFile("audio", "content/test");
14 testExpected("audio.volume", 1); 14 testExpected("audio.volume", 1);
15 waitForEvent("loadedmetadata", function() 15 waitForEvent("loadedmetadata", function()
16 { 16 {
17 // click the middle of the volume slider 17 // Click at 25% of the volume slider, to avoid hitting
philipj_slow 2015/07/08 10:31:51 Perhaps this isn't a new bug, but now that the are
liberato (no reviews please) 2015/07/09 12:10:53 sounds good.
liberato (no reviews please) 2015/07/14 22:10:36 done.
18 var coords = mediaControlsButtonCoordinates(audio, "volume-slide r"); 18 // the thumb touch rectangle. That would cause no
19 // slider movement.
20 var slider = mediaControlsButton(audio, "volume-slider");
21 var boundingRect = slider.getBoundingClientRect();
22 coords = [ boundingRect.left + boundingRect.width * 0.25,
23 boundingRect.top + boundingRect.height / 2 ];
24
19 eventSender.mouseMoveTo(coords[0], coords[1]); 25 eventSender.mouseMoveTo(coords[0], coords[1]);
20 eventSender.mouseDown(); 26 eventSender.mouseDown();
21 eventSender.mouseUp(); 27 eventSender.mouseUp();
22 28
23 testExpected("audio.volume", 0.4, '>'); 29 testExpected("audio.volume", 0.15, '>');
24 testExpected("audio.volume", 0.6, '<'); 30 testExpected("audio.volume", 0.35, '<');
25 waitForEventAndEnd("volumechange"); 31 waitForEventAndEnd("volumechange");
26 }); 32 });
27 </script> 33 </script>
28 </body> 34 </body>
29 </html> 35 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698