| Index: Source/core/editing/CompositeEditCommand.cpp
|
| diff --git a/Source/core/editing/CompositeEditCommand.cpp b/Source/core/editing/CompositeEditCommand.cpp
|
| index e05df2ca12e94aeec032c1b456f1697eed4e9920..e461eb2ec209c6c5d3e014321a5b6108212ce7af 100644
|
| --- a/Source/core/editing/CompositeEditCommand.cpp
|
| +++ b/Source/core/editing/CompositeEditCommand.cpp
|
| @@ -360,7 +360,12 @@ void CompositeEditCommand::insertNodeAt(PassRefPtrWillBeRawPtr<Node> insertChild
|
|
|
| void CompositeEditCommand::appendNode(PassRefPtrWillBeRawPtr<Node> node, PassRefPtrWillBeRawPtr<ContainerNode> parent)
|
| {
|
| - ASSERT(canHaveChildrenForEditing(parent.get()));
|
| + // When cloneParagraphUnderNewElement() clones the fallback content
|
| + // of an OBJECT element, the ASSERT below may fire since the return
|
| + // value of canHaveChildrenForEditing is not reliable until the render
|
| + // object of the OBJECT is created. Hence we ignore this check for OBJECTs.
|
| + ASSERT(canHaveChildrenForEditing(parent.get())
|
| + || (parent->isElementNode() && toElement(parent.get())->tagQName() == objectTag));
|
| applyCommandToComposite(AppendNodeCommand::create(parent, node));
|
| }
|
|
|
|
|