Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(69)

Unified Diff: Source/core/dom/ContainerNode.cpp

Issue 25389004: Notify nodes removal to Range/Selection after dispatching blur and mutation event (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: 2013-10-07T14:24:36 Created 7 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « LayoutTests/fast/dom/Range/range-created-during-remove-children-expected.txt ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/ContainerNode.cpp
diff --git a/Source/core/dom/ContainerNode.cpp b/Source/core/dom/ContainerNode.cpp
index 89eaf0f4a30147cc9c6c3282a8ab4afd045e32eb..b1e0cfbc50be64fb14c006ad83422a230e84dd8d 100644
--- a/Source/core/dom/ContainerNode.cpp
+++ b/Source/core/dom/ContainerNode.cpp
@@ -402,8 +402,6 @@ static void willRemoveChildren(ContainerNode* container)
NodeVector children;
getChildNodes(container, children);
- container->document().nodeChildrenWillBeRemoved(container);
-
ChildListMutationScope mutation(container);
for (NodeVector::const_iterator it = children.begin(); it != children.end(); it++) {
Node* child = it->get();
@@ -546,6 +544,8 @@ void ContainerNode::removeChildren()
document().removeFocusedElementOfSubtree(this, true);
}
+ document().nodeChildrenWillBeRemoved(this);
+
NodeVector removedChildren;
{
RenderWidget::UpdateSuspendScope suspendWidgetHierarchyUpdates;
« no previous file with comments | « LayoutTests/fast/dom/Range/range-created-during-remove-children-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698