OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 #ifndef CHROME_BROWSER_EXTENSIONS_API_WEBRTC_AUDIO_PRIVATE_WEBRTC_AUDIO_PRIVATE_
API_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_API_WEBRTC_AUDIO_PRIVATE_WEBRTC_AUDIO_PRIVATE_
API_H_ |
6 #define CHROME_BROWSER_EXTENSIONS_API_WEBRTC_AUDIO_PRIVATE_WEBRTC_AUDIO_PRIVATE_
API_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_API_WEBRTC_AUDIO_PRIVATE_WEBRTC_AUDIO_PRIVATE_
API_H_ |
7 | 7 |
8 #include "base/memory/ref_counted.h" | 8 #include "base/memory/ref_counted.h" |
9 #include "base/system_monitor/system_monitor.h" | 9 #include "base/system_monitor/system_monitor.h" |
10 #include "chrome/browser/extensions/api/profile_keyed_api_factory.h" | 10 #include "chrome/browser/extensions/api/profile_keyed_api_factory.h" |
11 #include "chrome/browser/extensions/chrome_extension_function.h" | 11 #include "chrome/browser/extensions/chrome_extension_function.h" |
12 #include "chrome/common/extensions/api/webrtc_audio_private.h" | 12 #include "chrome/common/extensions/api/webrtc_audio_private.h" |
13 #include "content/public/browser/render_view_host.h" | 13 #include "content/public/browser/render_view_host.h" |
14 #include "media/audio/audio_device_name.h" | 14 #include "media/audio/audio_device_name.h" |
15 #include "url/gurl.h" | 15 #include "url/gurl.h" |
16 | 16 |
| 17 namespace content { |
| 18 class ResourceContext; |
| 19 } |
| 20 |
17 namespace extensions { | 21 namespace extensions { |
18 | 22 |
19 // Listens for device changes and forwards as an extension event. | 23 // Listens for device changes and forwards as an extension event. |
20 class WebrtcAudioPrivateEventService | 24 class WebrtcAudioPrivateEventService |
21 : public ProfileKeyedAPI, | 25 : public ProfileKeyedAPI, |
22 public base::SystemMonitor::DevicesChangedObserver { | 26 public base::SystemMonitor::DevicesChangedObserver { |
23 public: | 27 public: |
24 explicit WebrtcAudioPrivateEventService(content::BrowserContext* context); | 28 explicit WebrtcAudioPrivateEventService(content::BrowserContext* context); |
25 virtual ~WebrtcAudioPrivateEventService(); | 29 virtual ~WebrtcAudioPrivateEventService(); |
26 | 30 |
(...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
217 // time, no locking needed. | 221 // time, no locking needed. |
218 scoped_ptr<api::webrtc_audio_private::GetAssociatedSink::Params> params_; | 222 scoped_ptr<api::webrtc_audio_private::GetAssociatedSink::Params> params_; |
219 | 223 |
220 // Audio sources (input devices). Filled in by DoWorkOnDeviceThread. | 224 // Audio sources (input devices). Filled in by DoWorkOnDeviceThread. |
221 media::AudioDeviceNames source_devices_; | 225 media::AudioDeviceNames source_devices_; |
222 }; | 226 }; |
223 | 227 |
224 } // namespace extensions | 228 } // namespace extensions |
225 | 229 |
226 #endif // CHROME_BROWSER_EXTENSIONS_API_WEBRTC_AUDIO_PRIVATE_WEBRTC_AUDIO_PRIVA
TE_API_H_ | 230 #endif // CHROME_BROWSER_EXTENSIONS_API_WEBRTC_AUDIO_PRIVATE_WEBRTC_AUDIO_PRIVA
TE_API_H_ |
OLD | NEW |