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

Side by Side Diff: LayoutTests/fast/events/mouseclick-target-and-positioning.html

Issue 14859016: Don't force layout for mouse event hit tests (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: fix review comment 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 function print(message, color) { 4 function print(message, color) {
5 var paragraph = document.createElement("div"); 5 var paragraph = document.createElement("div");
6 paragraph.appendChild(document.createTextNode(message)); 6 paragraph.appendChild(document.createTextNode(message));
7 paragraph.style.fontFamily = "monospace"; 7 paragraph.style.fontFamily = "monospace";
8 if (color) 8 if (color)
9 paragraph.style.color = color; 9 paragraph.style.color = color;
10 document.getElementById("console").appendChild(paragraph); 10 document.getElementById("console").appendChild(paragraph);
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 64
65 function test() { 65 function test() {
66 if (window.testRunner) { 66 if (window.testRunner) {
67 testRunner.dumpAsText(); 67 testRunner.dumpAsText();
68 testRunner.waitUntilDone(); 68 testRunner.waitUntilDone();
69 } 69 }
70 70
71 document.getElementById('test').addEventListener("click", listener, false); 71 document.getElementById('test').addEventListener("click", listener, false);
72 72
73 if (window.eventSender) { 73 if (window.eventSender) {
74 // Mouse events only work after an initial layout
75 document.body.offsetLeft;
74 eventSender.mouseMoveTo(175, 105); 76 eventSender.mouseMoveTo(175, 105);
75 eventSender.mouseDown(); 77 eventSender.mouseDown();
76 eventSender.mouseUp(); 78 eventSender.mouseUp();
77 } 79 }
78 80
79 if (window.testRunner) 81 if (window.testRunner)
80 testRunner.notifyDone(); 82 testRunner.notifyDone();
81 } 83 }
82 </script> 84 </script>
83 </head> 85 </head>
84 <body onload="test();"> 86 <body onload="test();">
85 <p>This page tests whether a click event propogates with the correct target and positioning. 87 <p>This page tests whether a click event propogates with the correct target and positioning.
86 See <a href="rdar://problem/4477126">rdar://problem/4477126</a>. 88 See <a href="rdar://problem/4477126">rdar://problem/4477126</a>.
87 </p> 89 </p>
88 <hr> 90 <hr>
89 <div style="position:absolute; top: 100"> 91 <div style="position:absolute; top: 100">
90 click inside the red box:<span id="test" style="position:absolute; left:160; col or:red">[]</span> 92 click inside the red box:<span id="test" style="position:absolute; left:160; col or:red">[]</span>
91 </div> 93 </div>
92 <div style="position:absolute; top: 150;" id='console'></div> 94 <div style="position:absolute; top: 150;" id='console'></div>
93 </body> 95 </body>
94 </html> 96 </html>
OLDNEW
« no previous file with comments | « LayoutTests/fast/events/mouse-focus-imagemap.html ('k') | LayoutTests/fast/events/mouseout-on-window.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698