4 <p>This test verifies that selection begins at the mouse-down position. Select rapidly inside the box blow. The first letter should be selected.
</p>
5 <div id='text'
style=
"border: solid 1px; padding: 10px;">The first part of this text should be selected.
</div>
8 testRunner
.dumpAsText();
10 if (window
.eventSender
) {
11 var div
= document
.getElementById('text');
12 var x
= div
.offsetLeft
+ 1;
13 var y
= div
.offsetTop
+ div
.offsetHeight
/ 2;
15 eventSender
.mouseMoveTo(x
, y
);
16 eventSender
.mouseDown();
18 eventSender
.mouseMoveTo(x
+ div
.offsetWidth
- 5, y
);
19 eventSender
.mouseUp();
21 var sel
= window
.getSelection();
22 document
.write(sel
.anchorNode
== sel
.focusNode
&& sel
.anchorOffset
< sel
.focusOffset
? 'PASS' : 'FAIL');