NEW 47916
selectAllChildren & extractContents do not extract all contents
https://bugs.webkit.org/show_bug.cgi?id=47916
Summary selectAllChildren & extractContents do not extract all contents
Ryosuke Niwa
Reported 2010-10-19 11:36:36 PDT
window.getSelection().selectAllChildren(test); window.getSelection().getRangeAt(0).extractContents(); does not extract all the contents in test because we canonicalize the selection. For example, if div was: <div id="test"><a href="http://webkit.org/">hello</a></div> The above script results in <div id="test"><a href="http://webkit.org/"></a></div> because the endContainer of getRangeAt(0) is "hello" (TextNode).
Attachments
Note You need to log in before you can comment on or make changes to this bug.