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

Unified Diff: content/browser/speech/speech_recognizer.cc

Issue 10933018: Speech JavaScript API: Use the MediaStreamManager to ask for user permission. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Addressing Satish's comments Created 8 years, 3 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: content/browser/speech/speech_recognizer.cc
diff --git a/content/browser/speech/speech_recognizer.cc b/content/browser/speech/speech_recognizer.cc
index 66a2fb3f0172308e5464ff8f7d04ae52e3689232..8078ba1615cfe8435d32929d48ae694399da2f60 100644
--- a/content/browser/speech/speech_recognizer.cc
+++ b/content/browser/speech/speech_recognizer.cc
@@ -255,12 +255,13 @@ SpeechRecognizer::ExecuteTransitionAndGetNextState(
// TODO(primiano): restore UNREACHABLE_CONDITION on EVENT_ABORT and
// EVENT_STOP_CAPTURE below once speech input extensions are fixed.
case EVENT_ABORT:
- return DoNothing(event_args);
+ return AbortSilently(event_args);
case EVENT_START:
return StartRecording(event_args);
- case EVENT_STOP_CAPTURE: // Corner cases related to queued messages
- case EVENT_AUDIO_DATA: // being lately dispatched.
- case EVENT_ENGINE_RESULT:
+ case EVENT_STOP_CAPTURE:
+ return AbortSilently(event_args);
+ case EVENT_AUDIO_DATA: // Corner cases related to queued messages
+ case EVENT_ENGINE_RESULT: // being lately dispatched.
case EVENT_ENGINE_ERROR:
case EVENT_AUDIO_ERROR:
return DoNothing(event_args);

Powered by Google App Engine
This is Rietveld 408576698