3 <title>Test controls with zooming
</title>
4 <style type=
"text/css" media=
"screen">
9 <script src=media-file.js
></script>
10 <script src=media-controls.js
></script>
11 <script type=
"text/javascript" charset=
"utf-8">
14 window.setTimeout(function() {
15 document.documentElement.style.zoom = '
150%';
16 video.addEventListener(
"playing", function() {
17 testExpected(
"video.paused", false);
21 if (window.eventSender)
23 // Find the play button and click the middle of its bounding box.
26 playCoords = mediaControlsButtonCoordinates(video,
"play-button");
28 failTest(exception.description);
31 var clickX = playCoords[
0];
32 var clickY = playCoords[
1];
34 // Apply the page zoom value to the coordinates because
35 // getBoundingClientRect() used in
36 // mediaControlsButtonCoordinates() doesn't do it.
37 clickX = clickX *
1.5;
38 clickY = clickY *
1.5;
40 eventSender.mouseMoveTo(clickX, clickY);
41 eventSender.mouseDown();
42 eventSender.mouseUp();
49 <video controls
></video>
50 <p>Test controls on zoomed video.
</p>
51 <p>This test only runs in DRT!
</p>
52 <script src=video-test.js
></script>
54 testExpected("video.controls", null, '!=');
55 waitForEvent('canplaythrough', function() {
58 video
.src
= findMediaFile("video", "content/test");