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

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

Issue 2714113003: Move ownership of IdleSpellCheckCallback from LocalFrame to SpellChecker (Closed)
Patch Set: Fri Feb 24 11:06:25 PST 2017 Created 3 years, 10 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 1e9624648685cc427e3049534186dbf33101a584..f13a3b9230f232e3b09b5606ed402ae9a345e741 100644
--- a/third_party/WebKit/Source/core/editing/spellcheck/SpellChecker.cpp
+++ b/third_party/WebKit/Source/core/editing/spellcheck/SpellChecker.cpp
@@ -43,6 +43,7 @@
#include "core/editing/commands/TypingCommand.h"
#include "core/editing/iterators/CharacterIterator.h"
#include "core/editing/markers/DocumentMarkerController.h"
+#include "core/editing/spellcheck/IdleSpellCheckCallback.h"
#include "core/editing/spellcheck/SpellCheckRequester.h"
#include "core/editing/spellcheck/TextCheckingParagraph.h"
#include "core/frame/LocalFrame.h"
@@ -165,7 +166,8 @@ TextCheckerClient& SpellChecker::textChecker() const {
SpellChecker::SpellChecker(LocalFrame& frame)
: m_frame(&frame),
- m_spellCheckRequester(SpellCheckRequester::create(frame)) {}
+ m_spellCheckRequester(SpellCheckRequester::create(frame)),
+ m_idleSpellCheckCallback(IdleSpellCheckCallback::create(frame)) {}
bool SpellChecker::isSpellCheckingEnabled() const {
return spellCheckerClient().isSpellCheckingEnabled();
@@ -1109,11 +1111,11 @@ void SpellChecker::cancelCheck() {
DEFINE_TRACE(SpellChecker) {
visitor->trace(m_frame);
visitor->trace(m_spellCheckRequester);
+ visitor->trace(m_idleSpellCheckCallback);
}
void SpellChecker::prepareForLeakDetection() {
- if (!RuntimeEnabledFeatures::idleTimeSpellCheckingEnabled())
- m_spellCheckRequester->prepareForLeakDetection();
+ m_spellCheckRequester->prepareForLeakDetection();
}
Vector<TextCheckingResult> SpellChecker::findMisspellings(const String& text) {
« no previous file with comments | « third_party/WebKit/Source/core/editing/spellcheck/SpellChecker.h ('k') | third_party/WebKit/Source/core/frame/LocalFrame.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698