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

Unified Diff: media/audio/mock_audio_manager.cc

Issue 10704154: Small refactor to media architecture in order to allow end-to-end tests. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Changed MockAudioManager ctor Created 8 years, 5 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 side-by-side diff with in-line comments
Download patch
Index: media/audio/mock_audio_manager.cc
diff --git a/media/audio/mock_audio_manager.cc b/media/audio/mock_audio_manager.cc
new file mode 100644
index 0000000000000000000000000000000000000000..46a8055571f351156fcdaff8a005ad8eaade9bc9
--- /dev/null
+++ b/media/audio/mock_audio_manager.cc
@@ -0,0 +1,79 @@
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "media/audio/mock_audio_manager.h"
+
+#include "base/logging.h"
+#include "base/message_loop_proxy.h"
+
+namespace media {
+
+MockAudioManager::MockAudioManager(
+ scoped_refptr<base::MessageLoopProxy> message_loop_proxy)
+ : message_loop_proxy_(message_loop_proxy) {
+}
+
+MockAudioManager::~MockAudioManager() {
+}
+
+bool MockAudioManager::HasAudioOutputDevices() {
+ return true;
+}
+
+bool MockAudioManager::HasAudioInputDevices() {
+ return true;
+}
+
+string16 MockAudioManager::GetAudioInputDeviceModel() {
+ return string16();
+}
+
+bool MockAudioManager::CanShowAudioInputSettings() {
+ return false;
+}
+
+void MockAudioManager::ShowAudioInputSettings() {
+}
+
+void MockAudioManager::GetAudioInputDeviceNames(
+ media::AudioDeviceNames* device_names) {
+}
+
+media::AudioOutputStream* MockAudioManager::MakeAudioOutputStream(
+ const media::AudioParameters& params) {
+ NOTREACHED();
+ return NULL;
+}
+
+media::AudioOutputStream* MockAudioManager::MakeAudioOutputStreamProxy(
+ const media::AudioParameters& params) {
+ NOTREACHED();
+ return NULL;
+}
+
+media::AudioInputStream* MockAudioManager::MakeAudioInputStream(
+ const media::AudioParameters& params,
+ const std::string& device_id) {
+ NOTREACHED();
+ return NULL;
+}
+
+void MockAudioManager::MuteAll() {
+}
+
+void MockAudioManager::UnMuteAll() {
+}
+
+bool MockAudioManager::IsRecordingInProcess() {
+ return false;
+}
+
+scoped_refptr<base::MessageLoopProxy> MockAudioManager::GetMessageLoop() {
+ return message_loop_proxy_;
+}
+
+void MockAudioManager::Init() {
+}
+
+} // namespace media.

Powered by Google App Engine
This is Rietveld 408576698