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

Unified Diff: third_party/WebKit/Source/core/editing/commands/CompositeEditCommand.cpp

Issue 2140733003: [Editing][CodeHealth] Make Node::rootEditableElement static (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 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
Index: third_party/WebKit/Source/core/editing/commands/CompositeEditCommand.cpp
diff --git a/third_party/WebKit/Source/core/editing/commands/CompositeEditCommand.cpp b/third_party/WebKit/Source/core/editing/commands/CompositeEditCommand.cpp
index ae58cce1d8a8334d62d187c27a89cbe1347474b4..9ceec27d7c56e1be0d1121859a5dc3596143bcb5 100644
--- a/third_party/WebKit/Source/core/editing/commands/CompositeEditCommand.cpp
+++ b/third_party/WebKit/Source/core/editing/commands/CompositeEditCommand.cpp
@@ -1065,7 +1065,7 @@ void CompositeEditCommand::cloneParagraphUnderNewElement(const Position& start,
Node* lastNode = nullptr;
Node* outerNode = passedOuterNode;
- if (outerNode->isRootEditableElement()) {
+ if (isRootEditableElement(*outerNode)) {
lastNode = blockElement;
} else {
lastNode = outerNode->cloneNode(isDisplayInsideTable(outerNode));
@@ -1394,7 +1394,7 @@ bool CompositeEditCommand::breakOutOfEmptyListItem(EditingState* editingState)
if (!listNode
|| (!isHTMLUListElement(*listNode) && !isHTMLOListElement(*listNode))
|| !listNode->hasEditableStyle()
- || listNode == emptyListItem->rootEditableElement())
+ || listNode == rootEditableElement(*emptyListItem))
return false;
HTMLElement* newBlock = nullptr;

Powered by Google App Engine
This is Rietveld 408576698