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

Unified Diff: content/browser/browser_main_loop.cc

Issue 2077983003: Intiialize AudioManager and related class lazily (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix MediaSessionTest Created 4 years, 5 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 | « no previous file | content/browser/renderer_host/render_process_host_impl.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 8c90372bed2931a50d01a8404fec70de81c6e0ff..438cf1e0783cd1f0f1787a61d18c7f6abb0cec23 100644
--- a/content/browser/browser_main_loop.cc
+++ b/content/browser/browser_main_loop.cc
@@ -1477,7 +1477,6 @@ void BrowserMainLoop::CreateAudioManager() {
DCHECK(!audio_thread_);
DCHECK(!audio_manager_);
- bool use_hang_monitor = true;
audio_manager_ = GetContentClient()->browser()->CreateAudioManager(
MediaInternals::GetInstance());
if (!audio_manager_) {
@@ -1489,9 +1488,6 @@ void BrowserMainLoop::CreateAudioManager() {
#if defined(OS_MACOSX)
// On Mac audio task runner must belong to the main thread.
// See http://crbug.com/158170.
- // Since the audio thread is the UI thread, a hang monitor is not
- // necessary or recommended.
- use_hang_monitor = false;
scoped_refptr<base::SingleThreadTaskRunner> audio_task_runner =
base::ThreadTaskRunnerHandle::Get();
#else
@@ -1505,9 +1501,6 @@ void BrowserMainLoop::CreateAudioManager() {
MediaInternals::GetInstance());
}
CHECK(audio_manager_);
-
- if (use_hang_monitor)
- media::AudioManager::StartHangMonitor(io_thread_->task_runner());
}
} // namespace content
« no previous file with comments | « no previous file | content/browser/renderer_host/render_process_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698