| Index: Source/core/editing/InsertListCommand.cpp
|
| diff --git a/Source/core/editing/InsertListCommand.cpp b/Source/core/editing/InsertListCommand.cpp
|
| index 9504168ce340d6bce9ae4ad266044a98ca01372d..f34712acdceb99fbab1e39a0679bf96e23b790a9 100644
|
| --- a/Source/core/editing/InsertListCommand.cpp
|
| +++ b/Source/core/editing/InsertListCommand.cpp
|
| @@ -55,7 +55,7 @@ PassRefPtr<HTMLElement> InsertListCommand::insertList(Document& document, Type t
|
|
|
| HTMLElement* InsertListCommand::fixOrphanedListChild(Node* node)
|
| {
|
| - RefPtr<HTMLElement> listElement = createUnorderedListElement(&document());
|
| + RefPtr<HTMLElement> listElement = createUnorderedListElement(document());
|
| insertNodeBefore(listElement, node);
|
| removeNode(node);
|
| appendNode(node, listElement);
|
| @@ -215,7 +215,7 @@ void InsertListCommand::doApplyForSingleParagraph(bool forceCreateList, const Qu
|
| bool rangeStartIsInList = visiblePositionBeforeNode(listNode.get()) == currentSelection->startPosition();
|
| bool rangeEndIsInList = visiblePositionAfterNode(listNode.get()) == currentSelection->endPosition();
|
|
|
| - RefPtr<HTMLElement> newList = createHTMLElement(&document(), listTag);
|
| + RefPtr<HTMLElement> newList = createHTMLElement(document(), listTag);
|
| insertNodeBefore(newList, listNode);
|
|
|
| Node* firstChildInList = enclosingListChild(VisiblePosition(firstPositionInNode(listNode.get())).deepEquivalent().deprecatedNode(), listNode.get());
|
| @@ -272,12 +272,12 @@ void InsertListCommand::unlistifyParagraph(const VisiblePosition& originalStart,
|
| }
|
| // When removing a list, we must always create a placeholder to act as a point of insertion
|
| // for the list content being removed.
|
| - RefPtr<Element> placeholder = createBreakElement(&document());
|
| + RefPtr<Element> placeholder = createBreakElement(document());
|
| RefPtr<Element> nodeToInsert = placeholder;
|
| // If the content of the list item will be moved into another list, put it in a list item
|
| // so that we don't create an orphaned list child.
|
| if (enclosingList(listNode)) {
|
| - nodeToInsert = createListItemElement(&document());
|
| + nodeToInsert = createListItemElement(document());
|
| appendNode(placeholder, nodeToInsert);
|
| }
|
|
|
| @@ -334,8 +334,8 @@ PassRefPtr<HTMLElement> InsertListCommand::listifyParagraph(const VisiblePositio
|
| return 0;
|
|
|
| // Check for adjoining lists.
|
| - RefPtr<HTMLElement> listItemElement = createListItemElement(&document());
|
| - RefPtr<HTMLElement> placeholder = createBreakElement(&document());
|
| + RefPtr<HTMLElement> listItemElement = createListItemElement(document());
|
| + RefPtr<HTMLElement> placeholder = createBreakElement(document());
|
| appendNode(placeholder, listItemElement);
|
|
|
| // Place list item into adjoining lists.
|
| @@ -348,7 +348,7 @@ PassRefPtr<HTMLElement> InsertListCommand::listifyParagraph(const VisiblePositio
|
| insertNodeAt(listItemElement, positionBeforeNode(nextList));
|
| else {
|
| // Create the list.
|
| - listElement = createHTMLElement(&document(), listTag);
|
| + listElement = createHTMLElement(document(), listTag);
|
| appendNode(listItemElement, listElement);
|
|
|
| if (start == end && isBlock(start.deepEquivalent().deprecatedNode())) {
|
|
|