Chromium Code Reviews| 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 #ifndef REMOTING_HOST_CLIENT_SESSION_H_ | 5 #ifndef REMOTING_HOST_CLIENT_SESSION_H_ |
| 6 #define REMOTING_HOST_CLIENT_SESSION_H_ | 6 #define REMOTING_HOST_CLIENT_SESSION_H_ |
| 7 | 7 |
| 8 #include <list> | 8 #include <list> |
| 9 | 9 |
| 10 #include "base/time.h" | 10 #include "base/time.h" |
| (...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 102 // be called multiple times. The object should not be used after | 102 // be called multiple times. The object should not be used after |
| 103 // this method returns. | 103 // this method returns. |
| 104 void Disconnect(); | 104 void Disconnect(); |
| 105 | 105 |
| 106 protocol::ConnectionToClient* connection() const { | 106 protocol::ConnectionToClient* connection() const { |
| 107 return connection_.get(); | 107 return connection_.get(); |
| 108 } | 108 } |
| 109 | 109 |
| 110 const std::string& client_jid() { return client_jid_; } | 110 const std::string& client_jid() { return client_jid_; } |
| 111 | 111 |
| 112 bool is_authenticated() { return is_authenticated_; } | |
|
Wez
2012/05/18 20:20:57
You can check |auth_input_filter_.get_stub()| here
Sergey Ulanov
2012/05/21 18:20:13
OnConnectionClosed() resets auth_input_filter_ and
Wez
2012/05/21 20:33:50
Hmmm, yes; the teardown logic in ChromotingHost re
Sergey Ulanov
2012/05/21 22:27:55
Added TODO.
| |
| 113 | |
| 112 // Indicate that local mouse activity has been detected. This causes remote | 114 // Indicate that local mouse activity has been detected. This causes remote |
| 113 // inputs to be ignored for a short time so that the local user will always | 115 // inputs to be ignored for a short time so that the local user will always |
| 114 // have the upper hand in 'pointer wars'. | 116 // have the upper hand in 'pointer wars'. |
| 115 void LocalMouseMoved(const SkIPoint& new_pos); | 117 void LocalMouseMoved(const SkIPoint& new_pos); |
| 116 | 118 |
| 117 // Disable handling of input events from this client. If the client has any | 119 // Disable handling of input events from this client. If the client has any |
| 118 // keys or mouse buttons pressed then these will be released. | 120 // keys or mouse buttons pressed then these will be released. |
| 119 void SetDisableInputs(bool disable_inputs); | 121 void SetDisableInputs(bool disable_inputs); |
| 120 | 122 |
| 121 private: | 123 private: |
| 122 EventHandler* event_handler_; | 124 EventHandler* event_handler_; |
| 123 | 125 |
| 124 // The connection to the client. | 126 // The connection to the client. |
| 125 scoped_ptr<protocol::ConnectionToClient> connection_; | 127 scoped_ptr<protocol::ConnectionToClient> connection_; |
| 126 | 128 |
| 127 std::string client_jid_; | 129 std::string client_jid_; |
| 130 bool is_authenticated_; | |
| 128 | 131 |
| 129 // The host event stub to which this object delegates. This is the final | 132 // The host event stub to which this object delegates. This is the final |
| 130 // element in the input pipeline, whose components appear in order below. | 133 // element in the input pipeline, whose components appear in order below. |
| 131 protocol::HostEventStub* host_event_stub_; | 134 protocol::HostEventStub* host_event_stub_; |
| 132 | 135 |
| 133 // Tracker used to release pressed keys and buttons when disconnecting. | 136 // Tracker used to release pressed keys and buttons when disconnecting. |
| 134 protocol::InputEventTracker input_tracker_; | 137 protocol::InputEventTracker input_tracker_; |
| 135 | 138 |
| 136 // Filter used to disable remote inputs during local input activity. | 139 // Filter used to disable remote inputs during local input activity. |
| 137 RemoteInputFilter remote_input_filter_; | 140 RemoteInputFilter remote_input_filter_; |
| (...skipping 12 matching lines...) Expand all Loading... | |
| 150 // TODO(lambroslambrou): Move floor-control logic, and clamping to screen | 153 // TODO(lambroslambrou): Move floor-control logic, and clamping to screen |
| 151 // area, out of this class (crbug.com/96508). | 154 // area, out of this class (crbug.com/96508). |
| 152 Capturer* capturer_; | 155 Capturer* capturer_; |
| 153 | 156 |
| 154 DISALLOW_COPY_AND_ASSIGN(ClientSession); | 157 DISALLOW_COPY_AND_ASSIGN(ClientSession); |
| 155 }; | 158 }; |
| 156 | 159 |
| 157 } // namespace remoting | 160 } // namespace remoting |
| 158 | 161 |
| 159 #endif // REMOTING_HOST_CLIENT_SESSION_H_ | 162 #endif // REMOTING_HOST_CLIENT_SESSION_H_ |
| OLD | NEW |