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

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

Issue 299353004: Oilpan: move editing objects to the heap. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Make test wrapper class finalized Created 6 years, 7 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 | « Source/core/editing/InsertListCommand.h ('k') | Source/core/editing/InsertNodeBeforeCommand.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/editing/InsertListCommand.cpp
diff --git a/Source/core/editing/InsertListCommand.cpp b/Source/core/editing/InsertListCommand.cpp
index de002bde53b7f56d3f4e8d48ab7e13eb6d34e28e..754eedb81ddddbda4d3c5b12b9244d0cc31eb592 100644
--- a/Source/core/editing/InsertListCommand.cpp
+++ b/Source/core/editing/InsertListCommand.cpp
@@ -279,8 +279,8 @@ 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> nodeToInsert = placeholder;
+ RefPtrWillBeRawPtr<Element> placeholder = createBreakElement(document());
+ RefPtrWillBeRawPtr<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)) {
@@ -362,7 +362,7 @@ PassRefPtrWillBeRawPtr<HTMLElement> InsertListCommand::listifyParagraph(const Vi
// Inserting the list into an empty paragraph that isn't held open
// by a br or a '\n', will invalidate start and end. Insert
// a placeholder and then recompute start and end.
- RefPtr<Node> placeholder = insertBlockPlaceholder(start.deepEquivalent());
+ RefPtrWillBeRawPtr<Node> placeholder = insertBlockPlaceholder(start.deepEquivalent());
start = VisiblePosition(positionBeforeNode(placeholder.get()));
end = start;
}
@@ -402,4 +402,10 @@ PassRefPtrWillBeRawPtr<HTMLElement> InsertListCommand::listifyParagraph(const Vi
return listElement;
}
+void InsertListCommand::trace(Visitor* visitor)
+{
+ visitor->trace(m_listElement);
+ CompositeEditCommand::trace(visitor);
+}
+
}
« no previous file with comments | « Source/core/editing/InsertListCommand.h ('k') | Source/core/editing/InsertNodeBeforeCommand.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698