| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 // AudioInputDeviceManagerEventHandler is used to signal events from | 5 // AudioInputDeviceManagerEventHandler is used to signal events from |
| 6 // AudioInoutDeviceManager when it's time to start and stop devices. | 6 // AudioInoutDeviceManager when it's time to start and stop devices. |
| 7 | 7 |
| 8 #ifndef CONTENT_BROWSER_RENDERER_HOST_MEDIA_AUDIO_INPUT_DEVICE_MANAGER_EVENT_HAN
DLER_H_ | 8 #ifndef CONTENT_BROWSER_RENDERER_HOST_MEDIA_AUDIO_INPUT_DEVICE_MANAGER_EVENT_HAN
DLER_H_ |
| 9 #define CONTENT_BROWSER_RENDERER_HOST_MEDIA_AUDIO_INPUT_DEVICE_MANAGER_EVENT_HAN
DLER_H_ | 9 #define CONTENT_BROWSER_RENDERER_HOST_MEDIA_AUDIO_INPUT_DEVICE_MANAGER_EVENT_HAN
DLER_H_ |
| 10 | 10 |
| 11 #include "content/common/content_export.h" | 11 #include "content/common/content_export.h" |
| 12 | 12 |
| 13 namespace media_stream { | 13 namespace media_stream { |
| 14 | 14 |
| 15 class CONTENT_EXPORT AudioInputDeviceManagerEventHandler { | 15 class CONTENT_EXPORT AudioInputDeviceManagerEventHandler { |
| 16 public: | 16 public: |
| 17 // Called by AudioInputDeviceManager to create an audio stream using the | 17 // Called by AudioInputDeviceManager to create an audio stream using the |
| 18 // device index when the device has been started. | 18 // device index when the device has been started. |
| 19 virtual void OnDeviceStarted(int session_id, | 19 virtual void OnDeviceStarted(int session_id, |
| 20 const std::string& device_id) = 0; | 20 const std::string& device_id) = 0; |
| 21 | 21 |
| 22 // Called by AudioInputDeviceManager to stop the audio stream when a device | 22 // Called by AudioInputDeviceManager to stop the audio stream when a device |
| 23 // has been stopped. This method is used only when users call Close() without | 23 // has been stopped. This method is used only when users call Close() without |
| 24 // calling Stop() on a started device. | 24 // calling Stop() on a started device. |
| 25 virtual void OnDeviceStopped(int session_id) = 0; | 25 virtual void OnDeviceStopped(int session_id) = 0; |
| 26 | 26 |
| 27 protected: |
| 27 virtual ~AudioInputDeviceManagerEventHandler() {} | 28 virtual ~AudioInputDeviceManagerEventHandler() {} |
| 28 }; | 29 }; |
| 29 | 30 |
| 30 } // namespace media_stream | 31 } // namespace media_stream |
| 31 | 32 |
| 32 #endif // CONTENT_BROWSER_RENDERER_HOST_MEDIA_AUDIO_INPUT_DEVICE_MANAGER_EVENT_
HANDLER_H_ | 33 #endif // CONTENT_BROWSER_RENDERER_HOST_MEDIA_AUDIO_INPUT_DEVICE_MANAGER_EVENT_
HANDLER_H_ |
| OLD | NEW |