Chromium Code Reviews| Index: LayoutTests/fullscreen/resources/video.html |
| diff --git a/LayoutTests/fullscreen/resources/video.html b/LayoutTests/fullscreen/resources/video.html |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..2db47099f11c35a986c618920b26e0d5313f9b5c |
| --- /dev/null |
| +++ b/LayoutTests/fullscreen/resources/video.html |
| @@ -0,0 +1,26 @@ |
| +<head> |
|
esprehn
2014/03/05 00:22:41
needs a doctype and drop the html, head and body
qinmin
2014/03/05 01:34:42
Done.
|
| +<script src="../../media/media-file.js"></script> |
| +<script> |
| +function canplaythrough() { |
| + parent.postMessage("Video loaded", "*"); |
| +} |
| + |
| +function fullscreenChanged() { |
| + parent.postMessage("SUCCEED - entered full screen!", "*"); |
| +} |
| + |
| +function runTest() { |
|
esprehn
2014/03/05 00:22:41
onload = function() {
qinmin
2014/03/05 01:34:42
Done.
|
| + var video = document.getElementById('video'); |
| + var mediaFile = findMediaFile("video", "../../media/content/test"); |
| + video.src = mediaFile; |
| + video.addEventListener('canplaythrough', canplaythrough); |
| + video.addEventListener('webkitfullscreenchange', fullscreenChanged); |
| + video.onclick = function() { |
| + video.webkitRequestFullscreen(); |
| + }; |
| +} |
| +</script> |
| +</head> |
| +<body onload="runTest()"> |
| +<video id="video" controls width="320" height="240"></video> |
| +</body> |