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

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

Issue 2777863003: [InputEvent] Distinguish between soft line and hard line (Closed)
Patch Set: Created 3 years, 9 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/EditorCommand.cpp
diff --git a/third_party/WebKit/Source/core/editing/commands/EditorCommand.cpp b/third_party/WebKit/Source/core/editing/commands/EditorCommand.cpp
index 63577489902fdb90742b8e980b878f3f1f8e0941..478fcb4edd8914ed027acc48bf0d2012a08651b9 100644
--- a/third_party/WebKit/Source/core/editing/commands/EditorCommand.cpp
+++ b/third_party/WebKit/Source/core/editing/commands/EditorCommand.cpp
@@ -152,16 +152,18 @@ InputEvent::InputType InputTypeFromCommandType(
case CommandType::DeleteForward:
return InputType::DeleteContentForward;
case CommandType::DeleteToBeginningOfLine:
- return InputType::DeleteLineBackward;
+ return InputType::DeleteSoftLineBackward;
case CommandType::DeleteToEndOfLine:
- return InputType::DeleteLineForward;
+ return InputType::DeleteSoftLineForward;
case CommandType::DeleteWordBackward:
return InputType::DeleteWordBackward;
case CommandType::DeleteWordForward:
return InputType::DeleteWordForward;
- // TODO(chongz): Find appreciate InputType for following commands.
case CommandType::DeleteToBeginningOfParagraph:
+ return InputType::DeleteHardLineBackward;
case CommandType::DeleteToEndOfParagraph:
+ return InputType::DeleteHardLineForward;
+ // TODO(chongz): Find appreciate InputType for following commands.
case CommandType::DeleteToMark:
return InputType::None;

Powered by Google App Engine
This is Rietveld 408576698