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

Side by Side Diff: LayoutTests/fast/events/capture-on-target.html

Issue 15508003: Revert "Don't force layout for mouse event hit tests" (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 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 <html> 1 <html>
2 <head> 2 <head>
3 <script> 3 <script>
4 4
5 if (window.testRunner) { 5 if (window.testRunner) {
6 testRunner.dumpAsText(); 6 testRunner.dumpAsText();
7 testRunner.waitUntilDone(); 7 testRunner.waitUntilDone();
8 } 8 }
9 function test() 9 function test()
10 { 10 {
11 document.getElementById("target").addEventListener("click", targetClick, tru e); 11 document.getElementById("target").addEventListener("click", targetClick, tru e);
12 12
13 if (window.eventSender) { 13 if (window.eventSender) {
14 // Mouse events only work after an initial layout
15 document.body.offsetLeft;
16 eventSender.mouseMoveTo(52, 52); 14 eventSender.mouseMoveTo(52, 52);
17 eventSender.mouseDown(); 15 eventSender.mouseDown();
18 eventSender.mouseUp(); 16 eventSender.mouseUp();
19 window.setTimeout(finish, 0); 17 window.setTimeout(finish, 0);
20 } 18 }
21 } 19 }
22 20
23 var finished = false; 21 var finished = false;
24 function finish() 22 function finish()
25 { 23 {
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
61 <body onload="test()"> 59 <body onload="test()">
62 60
63 <p>This tests checks that capturing event handlers trigger on the node that is the target of the event, and that stopPropagation in such a handler prevents further bubble handlers from triggering.</p> 61 <p>This tests checks that capturing event handlers trigger on the node that is the target of the event, and that stopPropagation in such a handler prevents further bubble handlers from triggering.</p>
64 <div onclick="containerClick(event)"> 62 <div onclick="containerClick(event)">
65 <div style="position:absolute; top: 40; left: 40; width: 100; height: 40 ; background-color: pink" id="target" onclick="targetClick(event)">Click here</a > 63 <div style="position:absolute; top: 40; left: 40; width: 100; height: 40 ; background-color: pink" id="target" onclick="targetClick(event)">Click here</a >
66 </div> 64 </div>
67 65
68 <div id="result" style="position: absolute; top: 100; left: 50;"><br></div> 66 <div id="result" style="position: absolute; top: 100; left: 50;"><br></div>
69 </body> 67 </body>
70 </html> 68 </html>
OLDNEW
« no previous file with comments | « LayoutTests/fast/dom/replaced-image-map.html ('k') | LayoutTests/fast/events/clientXY-in-zoom-and-scroll.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698