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

Side by Side Diff: LayoutTests/fast/html/details-add-summary-7-and-click.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 <script> 1 <script>
2 2
3 var createNewElement = function (tag, id, text) { 3 var createNewElement = function (tag, id, text) {
4 var result = document.createElement(tag); 4 var result = document.createElement(tag);
5 result.setAttribute('id',id); 5 result.setAttribute('id',id);
6 result.innerHTML = text; 6 result.innerHTML = text;
7 return result; 7 return result;
8 }; 8 };
9 9
10 var runTests = function () { 10 var runTests = function () {
11 document.getElementById("dt1").appendChild(createNewElement("summary", "new1 ", "new 1")); 11 document.getElementById("dt1").appendChild(createNewElement("summary", "new1 ", "new 1"));
12 document.getElementById("dt1").appendChild(createNewElement("summary", "new2 ", "new 2")); 12 document.getElementById("dt1").appendChild(createNewElement("summary", "new2 ", "new 2"));
13 13
14 if (!window.testRunner || !window.eventSender) 14 if (!window.testRunner || !window.eventSender)
15 return; 15 return;
16 // Mouse events only work after an initial layout
17 document.body.offsetLeft;
16 eventSender.mouseMoveTo(2, 2); 18 eventSender.mouseMoveTo(2, 2);
17 eventSender.mouseDown(); 19 eventSender.mouseDown();
18 eventSender.mouseUp(); 20 eventSender.mouseUp();
19 }; 21 };
20 22
21 </script> 23 </script>
22 24
23 <body style="margin: 0px" onload="runTests()"> 25 <body style="margin: 0px" onload="runTests()">
24 <details open id="dt1"></details> 26 <details open id="dt1"></details>
25 </body> 27 </body>
26 28
OLDNEW
« no previous file with comments | « LayoutTests/fast/html/details-add-summary-6-and-click.html ('k') | LayoutTests/fast/html/details-add-summary-8-and-click.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698