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

Side by Side Diff: LayoutTests/platform/chromium/fast/events/popup-forwarded-gesture-blocked.html

Issue 14120003: Move LayoutTests from platform/chromium/... to generic location (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 8 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
(Empty)
1 <!DOCTYPE html>
2 <html>
3 <body>
4 <p>
5 Test that a forwarded user gesture that is consumed before the
6 time fires is resurrected.
7 </p>
8 <button id="button" onclick="popup()">Click Here</button>
9 <div id="console"></div>
10 <script>
11 function timer() {
12 window.open("about:blank", "window2");
13 if (window.testRunner) {
14 if (testRunner.windowCount() == windowCount + 1)
15 document.getElementById("console").innerText = "PASSED";
16 else
17 document.getElementById("console").innerText = "FAILED";
18 testRunner.notifyDone();
19 }
20 }
21
22 function popup() {
23 setTimeout(timer, 0);
24 window.open("about:blank", "window1");
25 }
26
27 if (window.testRunner) {
28 testRunner.dumpAsText();
29 testRunner.setCanOpenWindows();
30 testRunner.setPopupBlockingEnabled(true);
31 testRunner.setCloseRemainingWindowsWhenComplete(true);
32 testRunner.waitUntilDone();
33 windowCount = testRunner.windowCount();
34
35 var button = document.getElementById("button");
36
37 if (window.eventSender) {
38 eventSender.mouseMoveTo(button.offsetLeft + button.offsetWid th / 2, button.offsetTop + button.offsetHeight / 2);
39 eventSender.mouseDown();
40 eventSender.mouseUp();
41 }
42 }
43 </script>
44 </body>
45 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698