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

Unified Diff: Source/core/editing/SpellChecker.cpp

Issue 67473002: Have ElementTraversal / NodeTraversal's next() methods take a reference (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase on master Created 7 years, 1 month 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 | « Source/core/editing/SimplifyMarkupCommand.cpp ('k') | Source/core/editing/TextIterator.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/editing/SpellChecker.cpp
diff --git a/Source/core/editing/SpellChecker.cpp b/Source/core/editing/SpellChecker.cpp
index ea460e7c33c8687e0fd2e04bec03aa3c1bbc779c..7c91e9a82fc398cbf8346668c32b60f6981ec858 100644
--- a/Source/core/editing/SpellChecker.cpp
+++ b/Source/core/editing/SpellChecker.cpp
@@ -96,7 +96,7 @@ void SpellChecker::toggleContinuousSpellChecking()
if (isContinuousSpellCheckingEnabled())
return;
for (Frame* frame = m_frame.page()->mainFrame(); frame && frame->document(); frame = frame->tree().traverseNext()) {
- for (Node* node = frame->document()->rootNode(); node; node = NodeTraversal::next(node)) {
+ for (Node* node = frame->document()->rootNode(); node; node = NodeTraversal::next(*node)) {
node->setAlreadySpellChecked(false);
}
}
@@ -726,7 +726,7 @@ void SpellChecker::didEndEditingOnTextField(Element* e)
DocumentMarker::MarkerTypes markerTypes(DocumentMarker::Spelling);
if (isGrammarCheckingEnabled() || unifiedTextCheckerEnabled())
markerTypes.add(DocumentMarker::Grammar);
- for (Node* node = innerText; node; node = NodeTraversal::next(node, innerText)) {
+ for (Node* node = innerText; node; node = NodeTraversal::next(*node, innerText)) {
m_frame.document()->markers()->removeMarkers(node, markerTypes);
}
}
« no previous file with comments | « Source/core/editing/SimplifyMarkupCommand.cpp ('k') | Source/core/editing/TextIterator.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698