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 #ifndef MEDIA_AUDIO_TEST_AUDIO_INPUT_CONTROLLER_FACTORY_H_ | 5 #ifndef MEDIA_AUDIO_TEST_AUDIO_INPUT_CONTROLLER_FACTORY_H_ |
6 #define MEDIA_AUDIO_TEST_AUDIO_INPUT_CONTROLLER_FACTORY_H_ | 6 #define MEDIA_AUDIO_TEST_AUDIO_INPUT_CONTROLLER_FACTORY_H_ |
7 | 7 |
8 #include "base/bind.h" | 8 #include "base/bind.h" |
9 #include "media/audio/audio_input_controller.h" | 9 #include "media/audio/audio_input_controller.h" |
10 | 10 |
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
54 | 54 |
55 TestAudioInputController(TestAudioInputControllerFactory* factory, | 55 TestAudioInputController(TestAudioInputControllerFactory* factory, |
56 AudioManager* audio_manager, | 56 AudioManager* audio_manager, |
57 const AudioParameters& audio_parameters, | 57 const AudioParameters& audio_parameters, |
58 EventHandler* event_handler, | 58 EventHandler* event_handler, |
59 SyncWriter* sync_writer); | 59 SyncWriter* sync_writer); |
60 | 60 |
61 // Returns the event handler installed on the AudioInputController. | 61 // Returns the event handler installed on the AudioInputController. |
62 EventHandler* event_handler() const { return event_handler_; } | 62 EventHandler* event_handler() const { return event_handler_; } |
63 | 63 |
64 // Returns the AudioParameters passed by the requester upon creation through | |
65 // AudioManager::Create(...). | |
66 const AudioParameters& audio_parameters() const { return audio_parameters_; } | |
67 | |
68 // Notifies the TestAudioControllerOpened() event to the delegate (if any). | 64 // Notifies the TestAudioControllerOpened() event to the delegate (if any). |
69 virtual void Record() OVERRIDE; | 65 virtual void Record() OVERRIDE; |
70 | 66 |
71 // Ensure that the closure is run on the audio-manager thread. | 67 // Ensure that the closure is run on the audio-manager thread. |
72 virtual void Close(const base::Closure& closed_task) OVERRIDE; | 68 virtual void Close(const base::Closure& closed_task) OVERRIDE; |
73 | 69 |
74 protected: | 70 protected: |
75 virtual ~TestAudioInputController(); | 71 virtual ~TestAudioInputController(); |
76 | 72 |
77 private: | 73 private: |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
116 | 112 |
117 // The delegate for tests for receiving audio controller events. | 113 // The delegate for tests for receiving audio controller events. |
118 TestAudioInputControllerDelegate* delegate_; | 114 TestAudioInputControllerDelegate* delegate_; |
119 | 115 |
120 DISALLOW_COPY_AND_ASSIGN(TestAudioInputControllerFactory); | 116 DISALLOW_COPY_AND_ASSIGN(TestAudioInputControllerFactory); |
121 }; | 117 }; |
122 | 118 |
123 } // namespace media | 119 } // namespace media |
124 | 120 |
125 #endif // MEDIA_AUDIO_TEST_AUDIO_INPUT_CONTROLLER_FACTORY_H_ | 121 #endif // MEDIA_AUDIO_TEST_AUDIO_INPUT_CONTROLLER_FACTORY_H_ |
OLD | NEW |