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

Side by Side Diff: LayoutTests/fast/lists/drag-into-marker.html

Issue 778003003: List marker pseudo elements. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 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
« no previous file with comments | « LayoutTests/fast/css/001.html ('k') | Source/core/core.gypi » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <body contenteditable="true"> 1 <body contenteditable="true">
2 2
3 <ul id="ul" style="margin:1em; border:1px solid black;"><li id="li" contentedita ble="true" style="list-style-type: square; font-size: 3em;">hello <span id="span ToDrag">world</span></a></div></li></ul> 3 <ul id="ul" style="margin:1em; border:1px solid black;"><li id="li" contentedita ble="true" style="list-style-type: square; font-size: 3em;">hello <span id="span ToDrag">world</span></a></div></li></ul>
4 4
5 <p>This is an automated test for elementAtPoint for points over position:outside list markers. The dictionary returned by elementAtPoint should contain the lis t item as the DOMNode, not the list, for points over position:outside list marke rs. elementAtPoint is used to determine the drag operation that will occur when something is dropped over a given point. So, this test drags a bit of text ove r the list marker and drops it. It should be pasted into the list item, which i s contenteditable.</p> 5 <p>This is an automated test for elementAtPoint for points over position:outside list markers. The dictionary returned by elementAtPoint should contain the lis t item as the DOMNode, not the list, for points over position:outside list marke rs. elementAtPoint is used to determine the drag operation that will occur when something is dropped over a given point. So, this test drags a bit of text ove r the list marker and drops it. It should be pasted into the list item, which i s contenteditable.</p>
6 6
7 <script> 7 <script>
8 8
9 function runTest() { 9 function runTest() {
10 if (!window.testRunner) 10 if (!window.testRunner)
(...skipping 16 matching lines...) Expand all
27 eventSender.mouseDown(); 27 eventSender.mouseDown();
28 // Wait a moment so that the mouseDown will kick off a drag instead of start ing a new selection. 28 // Wait a moment so that the mouseDown will kick off a drag instead of start ing a new selection.
29 eventSender.leapForward(400); 29 eventSender.leapForward(400);
30 30
31 var li = document.getElementById("li"); 31 var li = document.getElementById("li");
32 var ul = document.getElementById("ul"); 32 var ul = document.getElementById("ul");
33 33
34 // WebCore paints a position:outside list markers at an offset from the top left corner of the 34 // WebCore paints a position:outside list markers at an offset from the top left corner of the
35 // bounds of the list item. The offset is computed using a magic number and the 35 // bounds of the list item. The offset is computed using a magic number and the
36 // fonts ascent, two values we can't get to. This (x, y) *should* be over t he list marker. 36 // fonts ascent, two values we can't get to. This (x, y) *should* be over t he list marker.
37 var x = ul.offsetLeft + 18; 37 var x = ul.offsetLeft + 6;
38 var y = li.offsetTop + li.offsetHeight / 2 + 20; 38 var y = li.offsetTop + li.offsetHeight / 2 + 20;
39 39
40 eventSender.mouseMoveTo(x, y); 40 eventSender.mouseMoveTo(x, y);
41 eventSender.mouseUp(); 41 eventSender.mouseUp();
42 42
43 window.testRunner.notifyDone(); 43 window.testRunner.notifyDone();
44 } 44 }
45 45
46 runTest(); 46 runTest();
47 </script> 47 </script>
48 48
49 </body> 49 </body>
OLDNEW
« no previous file with comments | « LayoutTests/fast/css/001.html ('k') | Source/core/core.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698