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

Unified Diff: third_party/WebKit/Source/core/editing/spellcheck/SpellChecker.cpp

Issue 2432173005: Get rid of VisibleSelection::selectionFromContentsOfNode() (Closed)
Patch Set: 2016-10-20T17:14:18 Created 4 years, 2 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/spellcheck/SpellChecker.cpp
diff --git a/third_party/WebKit/Source/core/editing/spellcheck/SpellChecker.cpp b/third_party/WebKit/Source/core/editing/spellcheck/SpellChecker.cpp
index 36a46a159e260952460b45896a45532eae905477..62f41d21ddda4c3580dc03911ea6b189b6b167fb 100644
--- a/third_party/WebKit/Source/core/editing/spellcheck/SpellChecker.cpp
+++ b/third_party/WebKit/Source/core/editing/spellcheck/SpellChecker.cpp
@@ -217,8 +217,8 @@ void SpellChecker::didBeginEditing(Element* element) {
return;
// We always recheck textfields because markers are removed from them on
// blur.
- VisibleSelection selection =
- VisibleSelection::selectionFromContentsOfNode(element);
+ const VisibleSelection selection = createVisibleSelection(
+ SelectionInDOMTree::Builder().selectAllChildren(*element).build());
markMisspellingsAndBadGrammar(selection);
if (!isTextField)
parent->setAlreadySpellChecked(true);

Powered by Google App Engine
This is Rietveld 408576698