| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 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 "remoting/host/client_session.h" | 5 #include "remoting/host/client_session.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 | 8 |
| 9 #include "base/message_loop_proxy.h" | 9 #include "base/message_loop_proxy.h" |
| 10 #include "remoting/host/capturer.h" | 10 #include "remoting/host/capturer.h" |
| (...skipping 16 matching lines...) Expand all Loading... |
| 27 input_tracker_(host_event_stub), | 27 input_tracker_(host_event_stub), |
| 28 remote_input_filter_(&input_tracker_), | 28 remote_input_filter_(&input_tracker_), |
| 29 capturer_(capturer) { | 29 capturer_(capturer) { |
| 30 connection_->SetEventHandler(this); | 30 connection_->SetEventHandler(this); |
| 31 | 31 |
| 32 // TODO(sergeyu): Currently ConnectionToClient expects stubs to be | 32 // TODO(sergeyu): Currently ConnectionToClient expects stubs to be |
| 33 // set before channels are connected. Make it possible to set stubs | 33 // set before channels are connected. Make it possible to set stubs |
| 34 // later and set them only when connection is authenticated. | 34 // later and set them only when connection is authenticated. |
| 35 connection_->set_clipboard_stub(this); | 35 connection_->set_clipboard_stub(this); |
| 36 connection_->set_host_stub(this); | 36 connection_->set_host_stub(this); |
| 37 connection_->set_input_stub(&auth_input_filter_); | 37 connection_->set_input_stub(this); |
| 38 } | 38 } |
| 39 | 39 |
| 40 ClientSession::~ClientSession() { | 40 ClientSession::~ClientSession() { |
| 41 } | 41 } |
| 42 | 42 |
| 43 void ClientSession::InjectClipboardEvent( | 43 void ClientSession::InjectClipboardEvent( |
| 44 const protocol::ClipboardEvent& event) { | 44 const protocol::ClipboardEvent& event) { |
| 45 DCHECK(CalledOnValidThread()); | 45 DCHECK(CalledOnValidThread()); |
| 46 | 46 |
| 47 // TODO(wez): Disable clipboard in both directions on local activity, and | 47 // TODO(wez): Disable clipboard in both directions on local activity, and |
| (...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 145 | 145 |
| 146 if (disable_inputs) { | 146 if (disable_inputs) { |
| 147 disable_input_filter_.set_input_stub(NULL); | 147 disable_input_filter_.set_input_stub(NULL); |
| 148 input_tracker_.ReleaseAll(); | 148 input_tracker_.ReleaseAll(); |
| 149 } else { | 149 } else { |
| 150 disable_input_filter_.set_input_stub(&remote_input_filter_); | 150 disable_input_filter_.set_input_stub(&remote_input_filter_); |
| 151 } | 151 } |
| 152 } | 152 } |
| 153 | 153 |
| 154 } // namespace remoting | 154 } // namespace remoting |
| OLD | NEW |