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

Unified Diff: third_party/WebKit/Source/core/editing/markers/TextMatchMarkerListImpl.cpp

Issue 2949763002: Introduce Position constructor with const Node& (Closed)
Patch Set: 2017-06-20T13:43:23 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/markers/TextMatchMarkerListImpl.cpp
diff --git a/third_party/WebKit/Source/core/editing/markers/TextMatchMarkerListImpl.cpp b/third_party/WebKit/Source/core/editing/markers/TextMatchMarkerListImpl.cpp
index 6a89e3c53b5321eec53b0925160bad61fc392189..1bf76df50444fb9bd314cb406330dcf9465ed2a2 100644
--- a/third_party/WebKit/Source/core/editing/markers/TextMatchMarkerListImpl.cpp
+++ b/third_party/WebKit/Source/core/editing/markers/TextMatchMarkerListImpl.cpp
@@ -58,8 +58,8 @@ DEFINE_TRACE(TextMatchMarkerListImpl) {
}
static void UpdateMarkerLayoutRect(const Node& node, TextMatchMarker& marker) {
- const Position start_position(&const_cast<Node&>(node), marker.StartOffset());
- const Position end_position(&const_cast<Node&>(node), marker.EndOffset());
+ const Position start_position(node, marker.StartOffset());
+ const Position end_position(node, marker.EndOffset());
EphemeralRange range(start_position, end_position);
marker.SetLayoutRect(LayoutRect(ComputeTextRect(range)));
}

Powered by Google App Engine
This is Rietveld 408576698