4 <script style=
"display: block">
17 <script style=
"display: block" src=
"../editing.js">
22 <div id=
"pastehere" contenteditable=
"true"></div>
23 <ul id=
"console"></ul>
25 if (window
.testRunner
)
26 testRunner
.dumpAsText();
28 var s
= window
.getSelection();
29 var p1
= document
.getElementById("test1");
31 s
.setBaseAndExtent(p1
, 0, document
.getElementById("test2"), 2);
32 document
.execCommand("Copy");
33 p1
= document
.getElementById("pastehere");
35 document
.execCommand("Paste");
37 log(document
.getElementById("pastehere").outerHTML
);
40 var li
= document
.createElement("li");
41 li
.appendChild(document
.createTextNode(str
));
42 var console
= document
.getElementById("console");
43 console
.appendChild(li
);