OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "content/browser/renderer_host/media/audio_input_renderer_host.h" | 5 #include "content/browser/renderer_host/media/audio_input_renderer_host.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/memory/shared_memory.h" | 8 #include "base/memory/shared_memory.h" |
9 #include "base/metrics/histogram.h" | 9 #include "base/metrics/histogram.h" |
10 #include "base/process/process.h" | 10 #include "base/process/process.h" |
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
47 pending_close(false) { | 47 pending_close(false) { |
48 } | 48 } |
49 | 49 |
50 AudioInputRendererHost::AudioEntry::~AudioEntry() {} | 50 AudioInputRendererHost::AudioEntry::~AudioEntry() {} |
51 | 51 |
52 AudioInputRendererHost::AudioInputRendererHost( | 52 AudioInputRendererHost::AudioInputRendererHost( |
53 media::AudioManager* audio_manager, | 53 media::AudioManager* audio_manager, |
54 MediaStreamManager* media_stream_manager, | 54 MediaStreamManager* media_stream_manager, |
55 AudioMirroringManager* audio_mirroring_manager, | 55 AudioMirroringManager* audio_mirroring_manager, |
56 media::UserInputMonitor* user_input_monitor) | 56 media::UserInputMonitor* user_input_monitor) |
57 : BrowserMessageFilter(AudioMsgStart), | 57 : audio_manager_(audio_manager), |
58 audio_manager_(audio_manager), | |
59 media_stream_manager_(media_stream_manager), | 58 media_stream_manager_(media_stream_manager), |
60 audio_mirroring_manager_(audio_mirroring_manager), | 59 audio_mirroring_manager_(audio_mirroring_manager), |
61 user_input_monitor_(user_input_monitor), | 60 user_input_monitor_(user_input_monitor), |
62 audio_log_(MediaInternals::GetInstance()->CreateAudioLog( | 61 audio_log_(MediaInternals::GetInstance()->CreateAudioLog( |
63 media::AudioLogFactory::AUDIO_INPUT_CONTROLLER)) {} | 62 media::AudioLogFactory::AUDIO_INPUT_CONTROLLER)) {} |
64 | 63 |
65 AudioInputRendererHost::~AudioInputRendererHost() { | 64 AudioInputRendererHost::~AudioInputRendererHost() { |
66 DCHECK(audio_entries_.empty()); | 65 DCHECK(audio_entries_.empty()); |
67 } | 66 } |
68 | 67 |
(...skipping 348 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
417 // TODO(hclam): Implement a faster look up method. | 416 // TODO(hclam): Implement a faster look up method. |
418 for (AudioEntryMap::iterator i = audio_entries_.begin(); | 417 for (AudioEntryMap::iterator i = audio_entries_.begin(); |
419 i != audio_entries_.end(); ++i) { | 418 i != audio_entries_.end(); ++i) { |
420 if (controller == i->second->controller.get()) | 419 if (controller == i->second->controller.get()) |
421 return i->second; | 420 return i->second; |
422 } | 421 } |
423 return NULL; | 422 return NULL; |
424 } | 423 } |
425 | 424 |
426 } // namespace content | 425 } // namespace content |
OLD | NEW |