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

Unified Diff: Source/core/editing/CompositeEditCommand.cpp

Issue 64103002: Make "InsertHTML" and "Indent" commands to handle DOM tree modification during processing (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: 2013-11-08T13:02:58 Created 7 years, 1 month 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
Index: Source/core/editing/CompositeEditCommand.cpp
diff --git a/Source/core/editing/CompositeEditCommand.cpp b/Source/core/editing/CompositeEditCommand.cpp
index ae7cebfceb0bea5a4f958b37bce6d3728d014522..d72e31c4f85cbfc478296ea131696222dcb9b99f 100644
--- a/Source/core/editing/CompositeEditCommand.cpp
+++ b/Source/core/editing/CompositeEditCommand.cpp
@@ -998,6 +998,11 @@ void CompositeEditCommand::cloneParagraphUnderNewElement(Position& start, Positi
}
}
+ // Scripts specified in javascript protocol may remove |outerNode|
+ // during insertion, e.g. <iframe src="javascript:...">
+ if (!outerNode->inDocument())
+ return;
+
// Handle the case of paragraphs with more than one node,
// cloning all the siblings until end.deprecatedNode() is reached.

Powered by Google App Engine
This is Rietveld 408576698