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 3 // found in the LICENSE file. 4 5 #include "remoting/host/host_mock_objects.h" 6 7 #include "base/message_loop/message_loop_proxy.h" 8 #include "base/single_thread_task_runner.h" 9 #include "net/base/ip_endpoint.h" 10 #include "remoting/base/auto_thread_task_runner.h" 11 #include "remoting/codec/audio_encoder.h" 12 #include "remoting/codec/video_encoder.h" 13 #include "remoting/host/audio_capturer.h" 14 #include "remoting/host/input_injector.h" 15 #include "remoting/proto/event.pb.h" 16 #include "remoting/protocol/transport.h" 17 #include "third_party/webrtc/modules/desktop_capture/desktop_capturer.h" 18 19 namespace remoting { 20 MockDesktopEnvironment()21MockDesktopEnvironment::MockDesktopEnvironment() {} 22 ~MockDesktopEnvironment()23MockDesktopEnvironment::~MockDesktopEnvironment() {} 24 CreateAudioCapturer()25scoped_ptr<AudioCapturer> MockDesktopEnvironment::CreateAudioCapturer() { 26 return scoped_ptr<AudioCapturer>(CreateAudioCapturerPtr()); 27 } 28 CreateInputInjector()29scoped_ptr<InputInjector> MockDesktopEnvironment::CreateInputInjector() { 30 return scoped_ptr<InputInjector>(CreateInputInjectorPtr()); 31 } 32 CreateScreenControls()33scoped_ptr<ScreenControls> MockDesktopEnvironment::CreateScreenControls() { 34 return scoped_ptr<ScreenControls>(CreateScreenControlsPtr()); 35 } 36 37 scoped_ptr<webrtc::DesktopCapturer> CreateVideoCapturer()38MockDesktopEnvironment::CreateVideoCapturer() { 39 return scoped_ptr<webrtc::DesktopCapturer>(CreateVideoCapturerPtr()); 40 } 41 42 scoped_ptr<GnubbyAuthHandler> CreateGnubbyAuthHandler(protocol::ClientStub * client_stub)43MockDesktopEnvironment::CreateGnubbyAuthHandler( 44 protocol::ClientStub* client_stub) { 45 return scoped_ptr<GnubbyAuthHandler>(CreateGnubbyAuthHandlerPtr(client_stub)); 46 } 47 48 scoped_ptr<webrtc::MouseCursorMonitor> CreateMouseCursorMonitor()49MockDesktopEnvironment::CreateMouseCursorMonitor() { 50 return scoped_ptr<webrtc::MouseCursorMonitor>(CreateMouseCursorMonitorPtr()); 51 } 52 MockDesktopEnvironmentFactory()53MockDesktopEnvironmentFactory::MockDesktopEnvironmentFactory() {} 54 ~MockDesktopEnvironmentFactory()55MockDesktopEnvironmentFactory::~MockDesktopEnvironmentFactory() {} 56 Create(base::WeakPtr<ClientSessionControl> client_session_control)57scoped_ptr<DesktopEnvironment> MockDesktopEnvironmentFactory::Create( 58 base::WeakPtr<ClientSessionControl> client_session_control) { 59 return scoped_ptr<DesktopEnvironment>(CreatePtr()); 60 } 61 MockInputInjector()62MockInputInjector::MockInputInjector() {} 63 ~MockInputInjector()64MockInputInjector::~MockInputInjector() {} 65 Start(scoped_ptr<protocol::ClipboardStub> client_clipboard)66void MockInputInjector::Start( 67 scoped_ptr<protocol::ClipboardStub> client_clipboard) { 68 StartPtr(client_clipboard.get()); 69 } 70 MockClientSessionControl()71MockClientSessionControl::MockClientSessionControl() {} 72 ~MockClientSessionControl()73MockClientSessionControl::~MockClientSessionControl() {} 74 MockClientSessionEventHandler()75MockClientSessionEventHandler::MockClientSessionEventHandler() {} 76 ~MockClientSessionEventHandler()77MockClientSessionEventHandler::~MockClientSessionEventHandler() {} 78 MockHostStatusObserver()79MockHostStatusObserver::MockHostStatusObserver() {} 80 ~MockHostStatusObserver()81MockHostStatusObserver::~MockHostStatusObserver() {} 82 MockGnubbyAuthHandler()83MockGnubbyAuthHandler::MockGnubbyAuthHandler() {} 84 ~MockGnubbyAuthHandler()85MockGnubbyAuthHandler::~MockGnubbyAuthHandler() {} 86 MockMouseCursorMonitor()87MockMouseCursorMonitor::MockMouseCursorMonitor() {} 88 ~MockMouseCursorMonitor()89MockMouseCursorMonitor::~MockMouseCursorMonitor() {} 90 91 } // namespace remoting 92