Index: talk/app/webrtc/fakemediacontroller.h |
diff --git a/talk/media/devices/macdevicemanager.h b/talk/app/webrtc/fakemediacontroller.h |
similarity index 64% |
copy from talk/media/devices/macdevicemanager.h |
copy to talk/app/webrtc/fakemediacontroller.h |
index 82e62f9698644daa98fe19994d1f722b08156491..5bf3e5fcf8556b914436c948d887468241ae2fae 100644 |
--- a/talk/media/devices/macdevicemanager.h |
+++ b/talk/app/webrtc/fakemediacontroller.h |
@@ -1,6 +1,6 @@ |
/* |
* libjingle |
- * Copyright 2004 Google Inc. |
+ * Copyright 2015 Google Inc. |
* |
* Redistribution and use in source and binary forms, with or without |
* modification, are permitted provided that the following conditions are met: |
@@ -25,32 +25,31 @@ |
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
*/ |
-#ifndef TALK_MEDIA_DEVICES_MACDEVICEMANAGER_H_ |
-#define TALK_MEDIA_DEVICES_MACDEVICEMANAGER_H_ |
+#ifndef TALK_APP_WEBRTC_FAKEMEDIACONTROLLER_H_ |
+#define TALK_APP_WEBRTC_FAKEMEDIACONTROLLER_H_ |
-#include <string> |
-#include <vector> |
- |
-#include "talk/media/devices/devicemanager.h" |
-#include "webrtc/base/sigslot.h" |
-#include "webrtc/base/stringencode.h" |
+#include "talk/app/webrtc/mediacontroller.h" |
+#include "webrtc/base/checks.h" |
namespace cricket { |
-class DeviceWatcher; |
- |
-class MacDeviceManager : public DeviceManager { |
+class FakeMediaController : public webrtc::MediaControllerInterface { |
public: |
- MacDeviceManager(); |
- virtual ~MacDeviceManager(); |
- |
- virtual bool GetVideoCaptureDevices(std::vector<Device>* devs); |
+ explicit FakeMediaController(cricket::ChannelManager* channel_manager, |
+ webrtc::Call* call) |
+ : channel_manager_(channel_manager), call_(call) { |
+ RTC_DCHECK(nullptr != channel_manager_); |
+ RTC_DCHECK(nullptr != call_); |
+ } |
+ ~FakeMediaController() override {} |
+ webrtc::Call* call_w() override { return call_; } |
+ cricket::ChannelManager* channel_manager() const override { |
+ return channel_manager_; |
+ } |
private: |
- virtual bool GetAudioDevices(bool input, std::vector<Device>* devs); |
- bool FilterDevice(const Device& d); |
+ cricket::ChannelManager* channel_manager_; |
+ webrtc::Call* call_; |
}; |
- |
} // namespace cricket |
- |
-#endif // TALK_MEDIA_DEVICES_MACDEVICEMANAGER_H_ |
+#endif // TALK_APP_WEBRTC_FAKEMEDIACONTROLLER_H_ |