Index: remoting/host/client_session.cc |
diff --git a/remoting/host/client_session.cc b/remoting/host/client_session.cc |
index 55e4decc1ca3bb70e29df4836cd787e0f1fbed1c..071442734a6b07451941d93dc97fc391ba49918c 100644 |
--- a/remoting/host/client_session.cc |
+++ b/remoting/host/client_session.cc |
@@ -481,6 +481,21 @@ scoped_ptr<protocol::ClipboardStub> ClientSession::CreateClipboardProxy() { |
base::MessageLoopProxy::current())); |
} |
+scoped_ptr<webrtc::ScreenCapturer> ClientSession::RequestScreenCapturer() { |
Sergey Ulanov
2014/07/29 06:59:18
After our discussion with Wez today, I don't think
aiguha
2014/07/29 17:06:26
Agreed.
|
+ // VideoScheduler must be stopped on one of these threads. |
+ DCHECK(video_capture_task_runner_->BelongsToCurrentThread() || |
+ network_task_runner_->BelongsToCurrentThread()); |
+ |
+ if (!video_scheduler_.get()) { |
+ LOG(ERROR) << "Video Scheduler was NULL, but shouldn't have been."; |
+ return scoped_ptr<webrtc::ScreenCapturer>(); |
+ } |
+ |
+ video_scheduler_->Stop(); |
+ |
+ return desktop_environment_->CreateVideoCapturer(); |
+} |
+ |
// TODO(sergeyu): Move this to SessionManager? |
// static |
scoped_ptr<VideoEncoder> ClientSession::CreateVideoEncoder( |