OLD | NEW |
1 <html> | 1 <html> |
2 <head> | 2 <head> |
3 <title>Test that video play does not work unless a user gesture is invol
ved in playing a video</title> | 3 <title>Test that video play does not work unless a user gesture is invol
ved in playing a video</title> |
4 <script src=media-controls.js></script> | 4 <script src=media-controls.js></script> |
5 <script src=media-file.js></script> | 5 <script src=media-file.js></script> |
6 <!-- TODO(philipj): Convert test to testharness.js. crbug.com/588956 | 6 <!-- TODO(foolip): Convert test to testharness.js. crbug.com/588956 |
7 (Please avoid writing new tests using video-test.js) --> | 7 (Please avoid writing new tests using video-test.js) --> |
8 <script src=video-test.js></script> | 8 <script src=video-test.js></script> |
9 <script> | 9 <script> |
10 var userGestureInitiated = 0; | 10 var userGestureInitiated = 0; |
11 if (window.internals) | 11 if (window.internals) |
12 window.internals.settings.setMediaPlaybackRequiresUserGesture(tr
ue); | 12 window.internals.settings.setMediaPlaybackRequiresUserGesture(tr
ue); |
13 | 13 |
14 function click() | 14 function click() |
15 { | 15 { |
16 if (window.eventSender) { | 16 if (window.eventSender) { |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
67 video.src = findMediaFile("video", "content/test"); | 67 video.src = findMediaFile("video", "content/test"); |
68 } | 68 } |
69 </script> | 69 </script> |
70 </head> | 70 </head> |
71 | 71 |
72 <body onload="start()"> | 72 <body onload="start()"> |
73 <p>Test that video play() does not work unless a user clicked on the play bu
tton.</p> | 73 <p>Test that video play() does not work unless a user clicked on the play bu
tton.</p> |
74 <video controls></video> | 74 <video controls></video> |
75 </body> | 75 </body> |
76 </html> | 76 </html> |
OLD | NEW |