Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(433)

Side by Side Diff: media/audio/test_audio_input_controller_factory.cc

Issue 2390153006: Audio input debug recording refactoring to reduce thread hops and simplify object ownership (Closed)
Patch Set: Rebase Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « media/audio/audio_input_writer.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 "media/audio/test_audio_input_controller_factory.h" 5 #include "media/audio/test_audio_input_controller_factory.h"
6 #include "media/audio/audio_input_writer.h"
6 #include "media/audio/audio_io.h" 7 #include "media/audio/audio_io.h"
7 8
8 namespace media { 9 namespace media {
9 10
10 TestAudioInputController::TestAudioInputController( 11 TestAudioInputController::TestAudioInputController(
11 TestAudioInputControllerFactory* factory, 12 TestAudioInputControllerFactory* factory,
12 AudioManager* audio_manager, 13 AudioManager* audio_manager,
13 const AudioParameters& audio_parameters, 14 const AudioParameters& audio_parameters,
14 EventHandler* event_handler, 15 EventHandler* event_handler,
15 SyncWriter* sync_writer, 16 SyncWriter* sync_writer,
16 UserInputMonitor* user_input_monitor) 17 UserInputMonitor* user_input_monitor)
17 : AudioInputController(event_handler, 18 : AudioInputController(event_handler,
18 sync_writer, 19 sync_writer,
20 nullptr,
19 user_input_monitor, 21 user_input_monitor,
20 false), 22 false),
21 audio_parameters_(audio_parameters), 23 audio_parameters_(audio_parameters),
22 factory_(factory), 24 factory_(factory),
23 event_handler_(event_handler) { 25 event_handler_(event_handler) {
24 task_runner_ = audio_manager->GetTaskRunner(); 26 task_runner_ = audio_manager->GetTaskRunner();
25 } 27 }
26 28
27 TestAudioInputController::~TestAudioInputController() { 29 TestAudioInputController::~TestAudioInputController() {
28 // Inform the factory so that it allows creating new instances in future. 30 // Inform the factory so that it allows creating new instances in future.
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 return controller_; 62 return controller_;
61 } 63 }
62 64
63 void TestAudioInputControllerFactory::OnTestAudioInputControllerDestroyed( 65 void TestAudioInputControllerFactory::OnTestAudioInputControllerDestroyed(
64 TestAudioInputController* controller) { 66 TestAudioInputController* controller) {
65 DCHECK_EQ(controller_, controller); 67 DCHECK_EQ(controller_, controller);
66 controller_ = NULL; 68 controller_ = NULL;
67 } 69 }
68 70
69 } // namespace media 71 } // namespace media
OLDNEW
« no previous file with comments | « media/audio/audio_input_writer.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698