| OLD | NEW |
| (Empty) |
| 1 <html> | |
| 2 <head> | |
| 3 <title>Test rendering of volume slider of video tag</title> | |
| 4 <script src=media-file.js></script> | |
| 5 <script src=media-controls.js></script> | |
| 6 <script> | |
| 7 var video; | |
| 8 | |
| 9 function init() | |
| 10 { | |
| 11 if (window.testRunner) | |
| 12 testRunner.waitUntilDone(); | |
| 13 | |
| 14 video = document.getElementsByTagName("video")[0]; | |
| 15 video.src = findMediaFile("video", "content/test"); | |
| 16 } | |
| 17 | |
| 18 function test() | |
| 19 { | |
| 20 video.volume = 0.7; | |
| 21 | |
| 22 if (window.eventSender) { | |
| 23 var muteCoords; | |
| 24 try { | |
| 25 muteCoords = mediaControlsButtonCoordinates(video, "mute-but
ton"); | |
| 26 } catch (exception) { | |
| 27 testRunner.notifyDone(); | |
| 28 return; | |
| 29 } | |
| 30 eventSender.mouseMoveTo(muteCoords[0], muteCoords[1]); | |
| 31 } | |
| 32 | |
| 33 video.addEventListener("volumechange", function() { | |
| 34 if (window.testRunner) | |
| 35 testRunner.notifyDone(); | |
| 36 }); | |
| 37 } | |
| 38 </script> | |
| 39 </head> | |
| 40 <body onload="init()"> | |
| 41 Tests if the volume slider is rendererd properly. This test assumes the<br> | |
| 42 volume slider is implmented and mouse over the right bottom corner of<br> | |
| 43 video element will show the volume slider.<br> | |
| 44 <video oncanplaythrough="test()" controls></video> | |
| 45 </body> | |
| 46 </html> | |
| OLD | NEW |