layout/base/tests/bug482484-ref.html

changeset 0
6474c204b198
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/layout/base/tests/bug482484-ref.html	Wed Dec 31 06:09:35 2014 +0100
     1.3 @@ -0,0 +1,18 @@
     1.4 +<!DOCTYPE HTML><html><head></head>
     1.5 +<body>
     1.6 +<div contentEditable="true" id="div" spellcheck="false"><p id="p">ABC</p></div>
     1.7 +<script>
     1.8 +  // Position the caret after the "A"
     1.9 +  var div = document.getElementById('div');
    1.10 +  var p = document.getElementById('p');
    1.11 +  div.focus();
    1.12 +  var sel = window.getSelection();
    1.13 +  sel.removeAllRanges();
    1.14 +  var range = document.createRange();
    1.15 +  range.setStart(p.firstChild, 1)
    1.16 +  range.setEnd(p.firstChild, 1);
    1.17 +  sel.addRange(range);
    1.18 +</script>
    1.19 +
    1.20 +</body>
    1.21 +</html>

mercurial