Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fullscreen / full-screen-remove-children.html
blob8e21f874216c80d2fd8975e55dc70f7d3def639b
1 <body>
2 <script src="full-screen-test.js"></script>
3 <div><span></span></div>
4 <script>
5 var callback;
6 var fullscreenChanged = function(event)
8 if (callback)
9 callback(event)
11 waitForEvent(document, 'webkitfullscreenchange', fullscreenChanged);
13 var span = document.getElementsByTagName('span')[0];
14 var div = span.parentNode;
16 var spanEnteredFullScreen = function(event) {
17 callback = spanExitedFullScreen;
18 testExpected("document.webkitCurrentFullScreenElement", span);
19 div.innerHTML = "";
22 var spanExitedFullScreen = function(event) {
23 callback = null;
24 testExpected("document.webkitCurrentFullScreenElement", null);
25 endTest();
28 callback = spanEnteredFullScreen;
29 runWithKeyDown(function(){span.webkitRequestFullScreen()});
30 </script>