| Index: LayoutTests/editing/caret/caret-type-for-user-select-none.html
|
| diff --git a/LayoutTests/editing/caret/caret-type-for-user-select-none.html b/LayoutTests/editing/caret/caret-type-for-user-select-none.html
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..5fc0d828dee36306999047c62a62b1b1c57d0b2c
|
| --- /dev/null
|
| +++ b/LayoutTests/editing/caret/caret-type-for-user-select-none.html
|
| @@ -0,0 +1,37 @@
|
| +<!DOCTYPE html>
|
| +<html>
|
| +<body>
|
| +<p id="description"></p>
|
| +<div style="cursor:progress; border: 2px solid red;" id="test">Try selecting this text by dragging the cursor. Progress cursor should be displayed while doing so.</div>
|
| +<div id="console"></div>
|
| +<script src="../../fast/js/resources/js-test-pre.js"></script>
|
| +<script>
|
| +if (window.eventSender && window.internals) {
|
| + description('Tests whether explicitly set caret style is retained on performing text selection');
|
| +
|
| + var div = document.getElementById("test");
|
| + div.focus();
|
| +
|
| + var y = div.offsetTop + div.offsetHeight / 2;
|
| +
|
| + function leapForwardAndMove(x) {
|
| + eventSender.leapForward(200);
|
| + eventSender.mouseMoveTo(div.offsetLeft + x, y);
|
| + }
|
| +
|
| + eventSender.dragMode = false;
|
| + leapForwardAndMove(div.offsetLeft + 5, y);
|
| + eventSender.mouseDown();
|
| +
|
| + leapForwardAndMove(10);
|
| +
|
| + leapForwardAndMove(div.offsetWidth - 10);
|
| +
|
| + var cursorInfo = window.internals.getCurrentCursorInfo(document);
|
| + var currentCursorType = cursorInfo.substring(cursorInfo.indexOf('=') + 1, cursorInfo.lastIndexOf(' '));
|
| + shouldBeEqualToString('currentCursorType', 'Progress');
|
| +}
|
| +</script>
|
| +<script src="../../fast/js/resources/js-test-post.js"></script>
|
| +</body>
|
| +</html>
|
|
|