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

Unified Diff: third_party/WebKit/Source/core/editing/serializers/Serialization.cpp

Issue 2952983002: Make Position::FirstPositionInNode() to take const Node& instead of Node* (Closed)
Patch Set: 2017-06-23T10:37:43 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/serializers/Serialization.cpp
diff --git a/third_party/WebKit/Source/core/editing/serializers/Serialization.cpp b/third_party/WebKit/Source/core/editing/serializers/Serialization.cpp
index 3f628d20a30dd0e349e91ec2dd0e2977b7108295..90407674b94c3c071e4a4ada4918120ba3216f14 100644
--- a/third_party/WebKit/Source/core/editing/serializers/Serialization.cpp
+++ b/third_party/WebKit/Source/core/editing/serializers/Serialization.cpp
@@ -209,7 +209,7 @@ static HTMLElement* HighestAncestorToWrapMarkup(
if (check_ancestor->GetLayoutObject()) {
HTMLElement* new_special_common_ancestor =
ToHTMLElement(HighestEnclosingNodeOfType(
- Position::FirstPositionInNode(check_ancestor),
+ Position::FirstPositionInNode(*check_ancestor),
&IsPresentationalHTMLElement, kCanCrossEditingBoundary,
constraining_ancestor));
if (new_special_common_ancestor)
@@ -229,8 +229,8 @@ static HTMLElement* HighestAncestorToWrapMarkup(
if (HTMLAnchorElement* enclosing_anchor =
toHTMLAnchorElement(EnclosingElementWithTag(
Position::FirstPositionInNode(special_common_ancestor
- ? special_common_ancestor
- : common_ancestor),
+ ? *special_common_ancestor
+ : *common_ancestor),
aTag)))
special_common_ancestor = enclosing_anchor;

Powered by Google App Engine
This is Rietveld 408576698