1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/layout/base/tests/bug512295-1.html Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,34 @@ 1.4 +<!DOCTYPE HTML><html class="reftest-wait"><head> 1.5 + <script type="text/javascript" src="/tests/SimpleTest/EventUtils.js"></script> 1.6 +</head> 1.7 +<body> 1.8 +<div contenteditable="true"> 1.9 +<p id="p">A B CD EFG<br> 1.10 + 1234567890</p> 1.11 +</div> 1.12 +x 1.13 +<script> 1.14 + // Position the caret after "A" 1.15 + var sel = window.getSelection(); 1.16 + sel.removeAllRanges(); 1.17 + var range = document.createRange(); 1.18 + var p = document.getElementById('p'); 1.19 + var t = p.firstChild; 1.20 + range.setStart(t, 1); 1.21 + range.setEnd(t, 1); 1.22 + sel.addRange(range); 1.23 + p.parentNode.focus(); 1.24 + 1.25 + SpecialPowers.Cu.import("resource://gre/modules/AsyncSpellCheckTestHelper.jsm", window); 1.26 + onSpellCheck(p.parentNode, function () { 1.27 + sendKey('DOWN'); // now after "1" 1.28 + sendKey('DOWN'); // now make sure we get to the end 1.29 + sendKey('DOWN'); // now make sure we get to the end 1.30 + sendKey('DOWN'); // now make sure we get to the end 1.31 + sendKey('DOWN'); // now make sure we get to the end 1.32 + sendKey('DOWN'); // now make sure we get to the end 1.33 + document.documentElement.classList.remove("reftest-wait"); 1.34 + }); 1.35 +</script> 1.36 +</body> 1.37 +</html>