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

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

Issue 2958483003: Make VisiblePosition::BeforeNode() to take const Node& instead of Node* (Closed)
Patch Set: 017-06-23T18:57:25 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/InsertLineBreakCommand.cpp
diff --git a/third_party/WebKit/Source/core/editing/commands/InsertLineBreakCommand.cpp b/third_party/WebKit/Source/core/editing/commands/InsertLineBreakCommand.cpp
index 4d8630f5f7f29783687248a4f9de637f1c08b5ca..80f43f98c60cb7122a52eb04583431bae7fe168c 100644
--- a/third_party/WebKit/Source/core/editing/commands/InsertLineBreakCommand.cpp
+++ b/third_party/WebKit/Source/core/editing/commands/InsertLineBreakCommand.cpp
@@ -137,7 +137,7 @@ void InsertLineBreakCommand::DoApply(EditingState* editing_state) {
GetDocument().UpdateStyleAndLayoutIgnorePendingStylesheets();
// Insert an extra br or '\n' if the just inserted one collapsed.
- if (!IsStartOfParagraph(VisiblePosition::BeforeNode(node_to_insert))) {
+ if (!IsStartOfParagraph(VisiblePosition::BeforeNode(*node_to_insert))) {
InsertNodeBefore(node_to_insert->cloneNode(false), node_to_insert,
editing_state);
if (editing_state->IsAborted())

Powered by Google App Engine
This is Rietveld 408576698