Index: Source/core/editing/WrapContentsInDummySpanCommand.cpp |
diff --git a/Source/core/editing/WrapContentsInDummySpanCommand.cpp b/Source/core/editing/WrapContentsInDummySpanCommand.cpp |
index 25e8d3e2c31a732ef6df86c48b68ffdda07ac7ff..2a9f803b44a7a758a422c5bfc563c97e3968008e 100644 |
--- a/Source/core/editing/WrapContentsInDummySpanCommand.cpp |
+++ b/Source/core/editing/WrapContentsInDummySpanCommand.cpp |
@@ -41,9 +41,8 @@ WrapContentsInDummySpanCommand::WrapContentsInDummySpanCommand(PassRefPtrWillBeR |
void WrapContentsInDummySpanCommand::executeApply() |
{ |
- WillBeHeapVector<RefPtrWillBeMember<Node> > children; |
- for (Node* child = m_element->firstChild(); child; child = child->nextSibling()) |
- children.append(child); |
+ NodeVector children; |
+ getChildNodes(*m_element, children); |
size_t size = children.size(); |
for (size_t i = 0; i < size; ++i) |
@@ -66,9 +65,8 @@ void WrapContentsInDummySpanCommand::doUnapply() |
if (!m_dummySpan || !m_element->hasEditableStyle()) |
return; |
- WillBeHeapVector<RefPtrWillBeMember<Node> > children; |
- for (Node* child = m_dummySpan->firstChild(); child; child = child->nextSibling()) |
- children.append(child); |
+ NodeVector children; |
+ getChildNodes(*m_dummySpan, children); |
size_t size = children.size(); |
for (size_t i = 0; i < size; ++i) |