Upstream version 7.36.149.0
[platform/framework/web/crosswalk.git] / src / third_party / WebKit / LayoutTests / editing / inserting / 5058163-2.html
1 <p>This tests for a bug where hitting return after a line break in text that preserves newlines wouldn't do anything.</p>
2 <div id="div" contenteditable="true" style="white-space: pre;">xxx
3 There should be an empty paragraph before this one, and the caret should be at the start of this paragraph.</div>
4 <script>
5 var sel = window.getSelection();
6 var div = document.getElementById("div");
7 var text = div.firstChild;
8 sel.collapse(text, 4);
9 document.execCommand("InsertParagraph");
10 </script>