summaryrefslogtreecommitdiffstats
path: root/content/browser/speech/speech_recognizer_impl.cc
diff options
context:
space:
mode:
authorjiayl@chromium.org <jiayl@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-08-15 22:02:40 +0000
committerjiayl@chromium.org <jiayl@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-08-15 22:02:40 +0000
commit61f697f26142f5081aaee176ccd82a2af170eabf (patch)
tree2dab2a85e1824e8b94ff4beafbaaff180f5778e0 /content/browser/speech/speech_recognizer_impl.cc
parent92be5a41c4a56014723da338a53f5cbed515fe77 (diff)
downloadchromium_src-61f697f26142f5081aaee176ccd82a2af170eabf.zip
chromium_src-61f697f26142f5081aaee176ccd82a2af170eabf.tar.gz
chromium_src-61f697f26142f5081aaee176ccd82a2af170eabf.tar.bz2
Adding key press detection in the browser process.
It works like this on the browser side: A new object UserInputMonitor is created on BrowserMainLoop and passed to AudioInputRendererHost to pass to AudioInputController. AudioInputController::DoRecord calls UserInputMonitor::AddKeyStrokeListener --> UserInputMonitor listens to system key events (only implemented on Linux) --> AudioInputController::OnKeyPressed is called and sets key_pressed_ --> When AudioInputController::OnData called, it writes key_pressed_ to shared memory along with the audio data buffer. On the renderer side a new param "key_pressed" is added through the code path of passing the flag to the webrtc voice engine. This CL includes all these changes except the implementation of UserInputMonitor for Windows and Mac. The impl of UserInputMonitor is mostly copied from remoting/host/local_input_monitor_linux.cc BUG= Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=217768 Review URL: https://chromiumcodereview.appspot.com/21183002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@217844 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/browser/speech/speech_recognizer_impl.cc')
-rw-r--r--content/browser/speech/speech_recognizer_impl.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/content/browser/speech/speech_recognizer_impl.cc b/content/browser/speech/speech_recognizer_impl.cc
index 2081b2f..2dae430 100644
--- a/content/browser/speech/speech_recognizer_impl.cc
+++ b/content/browser/speech/speech_recognizer_impl.cc
@@ -564,7 +564,7 @@ SpeechRecognizerImpl::StartRecording(const FSMEventArgs&) {
new OnDataConverter(input_parameters, output_parameters));
audio_controller_ = AudioInputController::Create(
- audio_manager, this, input_parameters, device_id_);
+ audio_manager, this, input_parameters, device_id_, NULL);
if (!audio_controller_.get()) {
return Abort(SpeechRecognitionError(SPEECH_RECOGNITION_ERROR_AUDIO));