Index: LayoutTests/pointer-lock/pointerlock-then-fullscreen.html |
diff --git a/LayoutTests/pointer-lock/pointerlockchange-event-on-lock-lost.html b/LayoutTests/pointer-lock/pointerlock-then-fullscreen.html |
similarity index 63% |
copy from LayoutTests/pointer-lock/pointerlockchange-event-on-lock-lost.html |
copy to LayoutTests/pointer-lock/pointerlock-then-fullscreen.html |
index 2f4ff241f5c9b23b3c03ef070f2f0cd5c8bc4f4a..bbefa35d5f4bacc729d30fcc6effd5ad68a61994 100644 |
--- a/LayoutTests/pointer-lock/pointerlockchange-event-on-lock-lost.html |
+++ b/LayoutTests/pointer-lock/pointerlock-then-fullscreen.html |
@@ -9,7 +9,7 @@ |
<div id="target1"></div> |
</div> |
<script> |
- description("Test that pointerlockchange event is dispatched when lock is lost.") |
+ description("Test pointerlock then fullscreen.") |
window.jsTestIsAsync = true; |
shouldBeDefined("window.testRunner"); |
@@ -23,12 +23,17 @@ |
}, |
function () { |
shouldBe("document.pointerLockElement", "targetDiv1"); |
- expectOnlyChangeEvent("Host initiated unlock."); |
- testRunner.didLosePointerLock(); |
- // doNextStep called by event handler. |
+ document.body.onmousedown = function () { |
+ targetDiv1.webkitRequestFullscreen(); |
+ } |
+ document.onwebkitfullscreenchange = function () { |
+ doNextStep(); |
+ } |
+ eventSender.mouseDown(); |
}, |
function () { |
- shouldBe("document.pointerLockElement", "null"); |
+ shouldBe("document.pointerLockElement", "targetDiv1"); |
+ shouldBe("document.webkitFullscreenElement", "targetDiv1"); |
doNextStep(); |
}, |
]; |