I'm wondering if anyone can provide me with example javascript/jquery code of how to use Firefox's new fullscreen (NOT just full window) mode API (see link below). Basically i'd like to click something that would cause the video to go full screen.
Based on the API it looks like i should be able to do something like what i know works in Safari (and Dev builds of Chrome):
$(function(){
$('#full').click(function(){
var video_player = document.getElementById("video");
video_player.onwebkitfullscreenchange = function (){};
video_player.webkitRequestFullScreen();
});
});
UPDATE As suggested by Alexander, tonight (11/10/11) I installed the "Nightly" build of Firefox 10 and the following code now works:
$(function(){
$('#full').click(function(){
var video_player = document.getElementById("video");
void video_player.mozRequestFullScreen(); //firefox nightly build as of 11/10/11
});
});
http://blog.pearce.org.nz/2011/11/firefoxs-html-full-screen-api-enabled.html
https://wiki.mozilla.org/index.php?title=Gecko:FullScreenAPI#requestFullScreen_method