HTML5 Video 全屏监听esc退出全屏事件方法

function checkFull(){
var isFull = document.fullscreenEnabled || window.fullScreen || document.webkitIsFullScreen || document.msFullscreenEnabled;
if(isFull === undefined) isFull = false;
return isFull;
}
$(window).resize(function () {
if (!checkFull()) {
console.log("退出全屏");
}
});

推荐阅读更多精彩内容