Index: media/audio/audio_manager.h |
diff --git a/media/audio/audio_manager.h b/media/audio/audio_manager.h |
index 5da521dcca33de4e76b0006cf64fefa39940bca0..1391742fe5f68a83e08da7e0aa3f052c22e5f4a9 100644 |
--- a/media/audio/audio_manager.h |
+++ b/media/audio/audio_manager.h |
@@ -47,7 +47,7 @@ class MEDIA_EXPORT AudioManager { |
// Similar to Create() except also schedules a monitor on the given task |
// runner to ensure the audio thread is not stuck for more than 60 seconds; if |
- // a hang is detected, the process will be crashed. |
+ // a hang is detected, the process will be crashed. See EnableHangMonitor(). |
static AudioManager* CreateWithHangTimer( |
AudioLogFactory* audio_log_factory, |
const scoped_refptr<base::SingleThreadTaskRunner>& monitor_task_runner); |
@@ -55,6 +55,12 @@ class MEDIA_EXPORT AudioManager { |
// Similar to Create() except uses a FakeAudioLogFactory for testing. |
static AudioManager* CreateForTesting(); |
+ // Enables the hang monitor for the AudioManager once it's created. Must be |
+ // called before the AudioManager is created. CreateWithHangTimer() requires |
+ // either switches::kEnableAudioHangMonitor to be present or this to have been |
+ // called previously to start the hang monitor. Does nothing on OSX. |
+ static void EnableHangMonitor(); |
+ |
// Should only be used for testing. Resets a previously-set |
// AudioManagerFactory. The instance of AudioManager is not affected. |
static void ResetFactoryForTesting(); |