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

Unified Diff: third_party/WebKit/Source/core/editing/Editor.cpp

Issue 2241293006: Remove parameter node from SpellChecker::chunkAndMarkAllMisspellingsAndBadGrammar (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add DCHECK Created 4 years, 4 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
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/editing/spellcheck/SpellChecker.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 3dfce44193cb8660f513ecea7a95fa790169c084..91df8d4815b927adecc3f63cd6212657ff8bc16b 100644
--- a/third_party/WebKit/Source/core/editing/Editor.cpp
+++ b/third_party/WebKit/Source/core/editing/Editor.cpp
@@ -714,7 +714,9 @@ void Editor::requestSpellcheckingAfterApplyingCommand(CompositeEditCommand* cmd)
const EphemeralRange& insertedRange = toReplaceSelectionCommand(cmd)->insertedRange();
if (insertedRange.isNull())
return;
- spellChecker().chunkAndMarkAllMisspellingsAndBadGrammar(cmd->endingSelection().rootEditableElement(), insertedRange);
+ // Patch crrev.com/2241293006 assumes the following equality. Revert if it fails.
+ DCHECK_EQ(cmd->endingSelection().rootEditableElement(), rootEditableElementOf(insertedRange.startPosition()));
+ spellChecker().chunkAndMarkAllMisspellingsAndBadGrammar(insertedRange);
}
void Editor::appliedEditing(CompositeEditCommand* cmd)
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/editing/spellcheck/SpellChecker.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698