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

Unified Diff: Source/modules/speech/SpeechRecognition.cpp

Issue 208273002: Remove usage of {,un}setPendingActivity from SpeechRecognition (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 9 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 | « Source/modules/speech/SpeechRecognition.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/modules/speech/SpeechRecognition.cpp
diff --git a/Source/modules/speech/SpeechRecognition.cpp b/Source/modules/speech/SpeechRecognition.cpp
index 054d8161a99aef41e1990ec1571787117ab03010..e6a6fc378abe9951a8073900f01f6203b33f59ae 100644
--- a/Source/modules/speech/SpeechRecognition.cpp
+++ b/Source/modules/speech/SpeechRecognition.cpp
@@ -52,7 +52,6 @@ void SpeechRecognition::start(ExceptionState& exceptionState)
return;
}
- setPendingActivity(this);
m_finalResults.clear();
m_controller->start(this, m_grammars.get(), m_lang, m_continuous, m_interimResults, m_maxAlternatives);
m_started = true;
@@ -142,7 +141,6 @@ void SpeechRecognition::didEnd()
m_stopping = false;
if (!m_stoppedByActiveDOMObject)
dispatchEvent(Event::create(EventTypeNames::end));
- unsetPendingActivity(this);
}
const AtomicString& SpeechRecognition::interfaceName() const
@@ -162,6 +160,11 @@ void SpeechRecognition::stop()
abort();
}
+bool SpeechRecognition::hasPendingActivity() const
+{
+ return m_started;
+}
+
SpeechRecognition::SpeechRecognition(ExecutionContext* context)
: ActiveDOMObject(context)
, m_grammars(SpeechGrammarList::create()) // FIXME: The spec is not clear on the default value for the grammars attribute.
« no previous file with comments | « Source/modules/speech/SpeechRecognition.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698