<p>This tests for a hang when performing InsertUnorderedList.</p> | |
<div contenteditable="true"> | |
<div>There should be two empty unordered list items below.</div> | |
<div id="start"><br></div> | |
<div><br></div> | |
<div id="end">This should be an unordered list item.</div> | |
</div> | |
<script> | |
var selection = window.getSelection(); | |
var div = document.getElementById("div"); | |
selection.setBaseAndExtent(start, 0, end, end.childNodes.length); | |
document.execCommand("InsertUnorderedList"); | |
</script> |