Chromium Code Reviews| Index: third_party/WebKit/Source/core/editing/Editor.cpp |
| diff --git a/third_party/WebKit/Source/core/editing/Editor.cpp b/third_party/WebKit/Source/core/editing/Editor.cpp |
| index 930cd6f9595eb65950c02a1b1e8ea478822e327e..297830fa63ff2c44340bbf324eae6e91f2c28415 100644 |
| --- a/third_party/WebKit/Source/core/editing/Editor.cpp |
| +++ b/third_party/WebKit/Source/core/editing/Editor.cpp |
| @@ -1055,15 +1055,12 @@ bool Editor::InsertTextWithoutSendingTextEvent( |
| bool select_inserted_text, |
| TextEvent* triggering_event, |
| InputEvent::InputType input_type) { |
| - if (text.IsEmpty()) |
| - return false; |
| - |
| const VisibleSelection& selection = SelectionForCommand(triggering_event); |
| if (!selection.IsContentEditable()) |
| return false; |
| GetSpellChecker().UpdateMarkersForWordsAffectedByEditing( |
| - IsSpaceOrNewline(text[0])); |
| + !text.IsEmpty() && IsSpaceOrNewline(text[0])); |
|
yosin_UTC9
2017/05/12 05:06:14
Good catch!
|
| // Insert the text |
| TypingCommand::InsertText( |