yosinch / editing

document.execCommand in JavaScript for Blink
4 stars 6 forks source link

unlink command doesn't keep selection after split tree for selection start #12

Closed yosinch closed 10 years ago

yosinch commented 10 years ago

See unlink.w3c.14

before: <div contenteditable><a href="http://www.google.com/">foo^barbaz</a>|</div>
after: <div contenteditable><a href="http://www.google.com/">foo</a>^barbaz|</div>

When creating SelectionTracker before splitting tree, it has start: NODE, "barbaz" end: NODE_AFTER, A