gecko-dev/dom/html/test/file_fullscreen-denied-inne...

25 строки
797 B
HTML
Исходник Обычный вид История

<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
</head>
<body onload="doRequestFullscreen()">
<script>
function doRequestFullscreen() {
function handler(evt) {
document.removeEventListener("mozfullscreenchange", handler);
document.removeEventListener("mozfullscreenerror", handler);
parent.is(evt.type, "mozfullscreenerror", "Request from " +
"an iframe without allowfullscreen should be denied");
parent.continueTest();
}
parent.ok(!document.mozFullScreenEnabled, "Fullscreen " +
"should not be enabled in an iframe without allowfullscreen");
document.addEventListener("mozfullscreenchange", handler);
document.addEventListener("mozfullscreenerror", handler);
document.documentElement.mozRequestFullScreen();
}
</script>
</body>
</html>