| 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 #include "media/audio/fake_audio_log_factory.h" | 5 #include "media/audio/fake_audio_log_factory.h" |
| 6 | 6 |
| 7 #include <string> |
| 8 |
| 7 namespace media { | 9 namespace media { |
| 8 | 10 |
| 9 class FakeAudioLogImpl : public AudioLog { | 11 class FakeAudioLogImpl : public AudioLog { |
| 10 public: | 12 public: |
| 11 FakeAudioLogImpl() {} | 13 FakeAudioLogImpl() {} |
| 12 ~FakeAudioLogImpl() override {} | 14 ~FakeAudioLogImpl() override {} |
| 13 void OnCreated(int component_id, | 15 void OnCreated(int component_id, |
| 14 const media::AudioParameters& params, | 16 const media::AudioParameters& params, |
| 15 const std::string& device_id) override {} | 17 const std::string& device_id) override {} |
| 16 void OnStarted(int component_id) override {} | 18 void OnStarted(int component_id) override {} |
| 17 void OnStopped(int component_id) override {} | 19 void OnStopped(int component_id) override {} |
| 18 void OnClosed(int component_id) override {} | 20 void OnClosed(int component_id) override {} |
| 19 void OnError(int component_id) override {} | 21 void OnError(int component_id) override {} |
| 20 void OnSetVolume(int component_id, double volume) override {} | 22 void OnSetVolume(int component_id, double volume) override {} |
| 23 void OnSwitchOutputDevice(int component_id, |
| 24 const std::string& device_id) override {} |
| 21 }; | 25 }; |
| 22 | 26 |
| 23 FakeAudioLogFactory::FakeAudioLogFactory() {} | 27 FakeAudioLogFactory::FakeAudioLogFactory() {} |
| 24 FakeAudioLogFactory::~FakeAudioLogFactory() {} | 28 FakeAudioLogFactory::~FakeAudioLogFactory() {} |
| 25 | 29 |
| 26 scoped_ptr<AudioLog> FakeAudioLogFactory::CreateAudioLog( | 30 scoped_ptr<AudioLog> FakeAudioLogFactory::CreateAudioLog( |
| 27 AudioComponent component) { | 31 AudioComponent component) { |
| 28 return scoped_ptr<AudioLog>(new FakeAudioLogImpl()); | 32 return scoped_ptr<AudioLog>(new FakeAudioLogImpl()); |
| 29 } | 33 } |
| 30 | 34 |
| 31 } // namespace media | 35 } // namespace media |
| OLD | NEW |