OLD | NEW |
| (Empty) |
1 <p>This tests for a bug moving down by a line from a line just above a ToDo, and
moving up by a line from just below a ToDo.</p> | |
2 <div id="div" contenteditable="true"> | |
3 <div id="above">Click anywhere in this line and move down.</div> | |
4 <table border="1" contenteditable="false"><tr><td>The caret <span style="color:
blue;" contenteditable="true">should</span> always go into the editable region.<
/td></tr></table> | |
5 <div id="below">Click anywhere in this line and move up.</div> | |
6 </div> | |
7 | |
8 <script> | |
9 if (window.testRunner) | |
10 window.testRunner.dumpEditingCallbacks(); | |
11 var selection = window.getSelection(); | |
12 var above = document.getElementById("above").firstChild; | |
13 selection.setPosition(above, 0); | |
14 selection.modify("move", "forward", "line"); | |
15 selection.setPosition(above, above.length); | |
16 selection.modify("move", "forward", "line"); | |
17 var below = document.getElementById("below").firstChild; | |
18 selection.setPosition(below, 0); | |
19 selection.modify("move", "backward", "line"); | |
20 selection.setPosition(below, below.length); | |
21 selection.modify("move", "backward", "line"); | |
22 </script> | |
OLD | NEW |