| OLD | NEW |
| 1 <script src="resources/text-based-repaint.js" type="text/javascript"></script> | 1 <script src="resources/text-based-repaint.js" type="text/javascript"></script> |
| 2 <script type="text/javascript"> | 2 <script type="text/javascript"> |
| 3 function repaintTest() { | 3 function repaintTest() { |
| 4 var e = document.getElementById("removeme"); | 4 var e = document.getElementById("removeme"); |
| 5 e.parentNode.removeChild(e); | 5 e.parentNode.removeChild(e); |
| 6 } | 6 } |
| 7 </script> | 7 </script> |
| 8 <body onload="runRepaintTest();" contenteditable="true"> | 8 <body onload="runRepaintAndPixelTest();" contenteditable="true"> |
| 9 <p>This tests to see if selection gaps are invalidated properly when content ins
ide the selection is removed. Only 'hello world' should have a selecton tint be
hind it.</p> | 9 <p>This tests to see if selection gaps are invalidated properly when content ins
ide the selection is removed. Only 'hello world' should have a selecton tint be
hind it.</p> |
| 10 <div id="test" style="width: 150px; border: 1px solid red; margin: 30px;">hello
<span id="removeme"> world hello world hello world hello world hello world hello
world hello world hello world hello</span> world<br></div> | 10 <div id="test" style="width: 150px; border: 1px solid red; margin: 30px;">hello
<span id="removeme"> world hello world hello world hello world hello world hello
world hello world hello world hello</span> world<br></div> |
| 11 <script> | 11 <script> |
| 12 var s = window.getSelection(); | 12 var s = window.getSelection(); |
| 13 var e = document.getElementById("test"); | 13 var e = document.getElementById("test"); |
| 14 s.setBaseAndExtent(e, 0, e, e.childNodes.length); | 14 s.setBaseAndExtent(e, 0, e, e.childNodes.length); |
| 15 </script> | 15 </script> |
| 16 </body> | 16 </body> |
| OLD | NEW |