Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(837)

Side by Side Diff: LayoutTests/http/tests/pointer-lock/requestPointerLock-can-not-transfer-between-documents.html

Issue 266533004: Create unprefixed versions of pointerlockchange & pointerlockerror events. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 <!DOCTYPE HTML> 1 <!DOCTYPE HTML>
2 <html> 2 <html>
3 <head> 3 <head>
4 <script src="/js-test-resources/js-test.js"></script> 4 <script src="/js-test-resources/js-test.js"></script>
5 <script src="../resources/pointer-lock/pointer-lock-test-harness.js"></script> 5 <script src="../resources/pointer-lock/pointer-lock-test-harness.js"></script>
6 </head> 6 </head>
7 <body> 7 <body>
8 <div> 8 <div>
9 <div id="target1"></div> 9 <div id="target1"></div>
10 <iframe src="../resources/pointer-lock/inner-iframe.html" onload="doNextStepWi thUserGesture()"></iframe> 10 <iframe src="../resources/pointer-lock/inner-iframe.html" onload="doNextStepWi thUserGesture()"></iframe>
(...skipping 12 matching lines...) Expand all
23 // doNextStep called by event handler. 23 // doNextStep called by event handler.
24 }, 24 },
25 function () { 25 function () {
26 shouldBe("document.webkitPointerLockElement", "targetDiv1"); 26 shouldBe("document.webkitPointerLockElement", "targetDiv1");
27 doNextStep(); 27 doNextStep();
28 }, 28 },
29 function () { 29 function () {
30 iframe.contentWindow.postMessage(["eval", 'document.body.webkitRequest PointerLock()'], "*"); 30 iframe.contentWindow.postMessage(["eval", 'document.body.webkitRequest PointerLock()'], "*");
31 window.onmessage = function (messageEvent) { 31 window.onmessage = function (messageEvent) {
32 message = messageEvent.data; 32 message = messageEvent.data;
33 shouldBeEqualToString("message", "inner-iframe.html onwebkitpointe rlockerror"); 33 shouldBeEqualToString("message", "inner-iframe.html onpointerlocke rror");
34 window.onmessage = null; 34 window.onmessage = null;
35 doNextStep(); 35 doNextStep();
36 } 36 }
37 }, 37 },
38 function () { 38 function () {
39 iframe.contentWindow.postMessage(["eval", 'document.webkitExitPointerL ock()'], "*"); 39 iframe.contentWindow.postMessage(["eval", 'document.webkitExitPointerL ock()'], "*");
40 window.onmessage = function (messageEvent) { 40 window.onmessage = function (messageEvent) {
41 testFailed("webkitExitPointerLock from a document that doesn't hav e a lock caused an event " + messageEvent.data); 41 testFailed("webkitExitPointerLock from a document that doesn't hav e a lock caused an event " + messageEvent.data);
42 finishJSTest(); 42 finishJSTest();
43 } 43 }
44 doNextStep(); 44 doNextStep();
45 }, 45 },
46 ]; 46 ];
47 // doNextStep() called by iframe onload handler. 47 // doNextStep() called by iframe onload handler.
48 </script> 48 </script>
49 </body> 49 </body>
50 </html> 50 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698