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

Unified Diff: chrome/browser/chrome_content_browser_client.cc

Issue 2582703003: Audio output debug recording. (Closed)
Patch Set: Code review. 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 | « no previous file | chrome/browser/media/audio_debug_recordings_handler.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chrome_content_browser_client.cc
diff --git a/chrome/browser/chrome_content_browser_client.cc b/chrome/browser/chrome_content_browser_client.cc
index be3a5cd9e2e95f4c774cfcb4c375dee6865fefae..543251e7c95a92d9e77d1500f5bb9faf55274886 100644
--- a/chrome/browser/chrome_content_browser_client.cc
+++ b/chrome/browser/chrome_content_browser_client.cc
@@ -185,6 +185,7 @@
#include "device/usb/public/interfaces/device_manager.mojom.h"
#include "extensions/features/features.h"
#include "gpu/config/gpu_switches.h"
+#include "media/audio/audio_manager.h"
#include "media/media_features.h"
#include "net/base/mime_util.h"
#include "net/base/registry_controlled_domains/registry_controlled_domain.h"
@@ -1184,8 +1185,10 @@ void ChromeContentBrowserClient::RenderProcessWillLaunch(
new base::UserDataAdapter<WebRtcLoggingHandlerHost>(
webrtc_logging_handler_host));
+ // The audio manager outlives the host, so it's safe to hand a raw pointer to
+ // it to the AudioDebugRecordingsHandler, which is owned by the host.
AudioDebugRecordingsHandler* audio_debug_recordings_handler =
- new AudioDebugRecordingsHandler(profile);
+ new AudioDebugRecordingsHandler(profile, media::AudioManager::Get());
host->SetUserData(
AudioDebugRecordingsHandler::kAudioDebugRecordingsHandlerKey,
new base::UserDataAdapter<AudioDebugRecordingsHandler>(
« no previous file with comments | « no previous file | chrome/browser/media/audio_debug_recordings_handler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698