-
eric@webkit.org authored
Reviewed by Darin Adler. DOM insertion mutation events should dispatch after a node is attached to the render tree https://bugs.webkit.org/show_bug.cgi?id=35590 * fast/events/domnodeinsertedintodocument-dispatched-post-rendering-expected.txt: Added. * fast/events/domnodeinsertedintodocument-dispatched-post-rendering.html: Added. 2010-03-04 Antoine Quint <ml@graougraou.com> Reviewed by Darin Adler. DOM insertion mutation events should dispatch after a node is attached to the render tree https://bugs.webkit.org/show_bug.cgi?id=35590 Test: fast/events/domnodeinsertedintodocument-dispatched-post-rendering.html Split off the internal-to-WebCore node insertion notification code from the DOM mutation event dispatching, originally in dispatchChildInsertionEvents(), to a new static function called notifyChildInserted(). This allows us to dispatch the mutation events at a later time upon insertion of a child into to the tree, specifically _after_ attachment to the render tree. * dom/ContainerNode.cpp: (WebCore::ContainerNode::insertBefore): (WebCore::ContainerNode::replaceChild): (WebCore::ContainerNode::appendChild): (WebCore::notifyChildInserted): (WebCore::dispatchChildInsertionEvents): git-svn-id: http://svn.webkit.org/repository/webkit/trunk@55532 268f45cc-cd09-0410-ab3c-d52691b4dbfc
e2511942