OLD | NEW |
(Empty) | |
| 1 <!DOCTYPE html> |
| 2 <script src="../../media/media-file.js"></script> |
| 3 <script> |
| 4 function canplaythrough() { |
| 5 parent.postMessage("Video loaded", "*"); |
| 6 } |
| 7 |
| 8 function fullscreenChanged() { |
| 9 parent.postMessage("SUCCEED - entered full screen!", "*"); |
| 10 } |
| 11 |
| 12 onload = function() { |
| 13 var video = document.getElementById('video'); |
| 14 var mediaFile = findMediaFile("video", "../../media/content/test"); |
| 15 video.src = mediaFile; |
| 16 video.addEventListener('canplaythrough', canplaythrough); |
| 17 video.addEventListener('webkitfullscreenchange', fullscreenChanged); |
| 18 video.onclick = function() { |
| 19 video.webkitRequestFullscreen(); |
| 20 }; |
| 21 } |
| 22 </script> |
| 23 <video id="video" controls width="320" height="240"></video> |
OLD | NEW |