blob: 07a0f7aa22e4b432a01c55e480ca5347a0f978ed [file] [log] [blame]
<script>
if (window.layoutTestController)
layoutTestController.dumpEditingCallbacks();
</script>
<p>This demonstrates a bug in interchange newline handling during paste. The selection being pasted into spans multiple blocks, which breaks the old code in paste that handled interchange newlines.</p>
<div id="test" contenteditable="true"><div>foo</div>bar</div>
<script>
var s = window.getSelection();
var e = document.getElementById("test");
s.setPosition(e, 0);
s.modify("move", "forward", "character");
s.modify("extend", "forward", "line");
document.execCommand("InsertHTML", false, "<div>bar</div>baz<br class='Apple-interchange-newline'>");
</script>