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

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

Issue 2955823002: Make VisiblePosition::FirstPositionInNode() to take const Node& instead of Node* (Closed)
Patch Set: 2017-06-26T17:50:06 Created 3 years, 6 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/ReplaceSelectionCommand.cpp
diff --git a/third_party/WebKit/Source/core/editing/commands/ReplaceSelectionCommand.cpp b/third_party/WebKit/Source/core/editing/commands/ReplaceSelectionCommand.cpp
index 7a6123b936026a9bdde19929b783e84ba58ccdda..a28357e8d29937dd7e01b2d601628aee23a6b678 100644
--- a/third_party/WebKit/Source/core/editing/commands/ReplaceSelectionCommand.cpp
+++ b/third_party/WebKit/Source/core/editing/commands/ReplaceSelectionCommand.cpp
@@ -630,9 +630,9 @@ void ReplaceSelectionCommand::RemoveRedundantStylesAndKeepStyleSpanInline(
// FIXME: Tolerate differences in id, class, and style attributes.
if (element->parentNode() && IsNonTableCellHTMLBlockElement(element) &&
AreIdenticalElements(*element, *element->parentNode()) &&
- VisiblePosition::FirstPositionInNode(element->parentNode())
+ VisiblePosition::FirstPositionInNode(*element->parentNode())
.DeepEquivalent() ==
- VisiblePosition::FirstPositionInNode(element).DeepEquivalent() &&
+ VisiblePosition::FirstPositionInNode(*element).DeepEquivalent() &&
VisiblePosition::LastPositionInNode(element->parentNode())
.DeepEquivalent() ==
VisiblePosition::LastPositionInNode(element).DeepEquivalent()) {

Powered by Google App Engine
This is Rietveld 408576698