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

Unified Diff: content/browser/browser_main_loop.cc

Issue 2675713002: Switch Speech Recognition to asynchronous callback-based AudioManager interactions. (Closed)
Patch Set: review comments addressed 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
« no previous file with comments | « content/browser/browser_main_loop.h ('k') | content/browser/speech/speech_recognition_browsertest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/browser_main_loop.cc
diff --git a/content/browser/browser_main_loop.cc b/content/browser/browser_main_loop.cc
index d70a6a48ff1d26ea7fffeea8308aa5b8f80aeb6e..5f1d5a510a8c7941d3dce7a1d7fe115b6e585cb8 100644
--- a/content/browser/browser_main_loop.cc
+++ b/content/browser/browser_main_loop.cc
@@ -92,6 +92,7 @@
#include "device/battery/battery_status_service.h"
#include "device/gamepad/gamepad_service.h"
#include "device/sensors/device_sensor_service.h"
+#include "media/audio/audio_system_impl.h"
#include "media/base/media.h"
#include "media/base/user_input_monitor.h"
#include "media/midi/midi_service.h"
@@ -1537,8 +1538,8 @@ int BrowserMainLoop::BrowserThreadsStarted() {
{
TRACE_EVENT0("startup",
"BrowserMainLoop::BrowserThreadsStarted:InitSpeechRecognition");
- speech_recognition_manager_.reset(
- new SpeechRecognitionManagerImpl(media_stream_manager_.get()));
+ speech_recognition_manager_.reset(new SpeechRecognitionManagerImpl(
Avi (use Gerrit) 2017/02/06 16:14:21 base::MakeUnique?
o1ka 2017/02/06 16:40:06 Unfortunately this won't compile: for some reason
+ audio_system_.get(), media_stream_manager_.get()));
}
{
@@ -1797,6 +1798,9 @@ void BrowserMainLoop::CreateAudioManager() {
MediaInternals::GetInstance());
}
CHECK(audio_manager_);
+
+ audio_system_ = media::AudioSystemImpl::Create(audio_manager_.get());
+ CHECK(audio_system_);
}
} // namespace content
« no previous file with comments | « content/browser/browser_main_loop.h ('k') | content/browser/speech/speech_recognition_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698