OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 #include <set> | 9 #include <set> |
10 | 10 |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
43 // Takes ownership of |user_authenticator|. Does not take ownership of | 43 // Takes ownership of |user_authenticator|. Does not take ownership of |
44 // |event_handler|, |input_stub| or |capturer|. | 44 // |event_handler|, |input_stub| or |capturer|. |
45 ClientSession(EventHandler* event_handler, | 45 ClientSession(EventHandler* event_handler, |
46 UserAuthenticator* user_authenticator, | 46 UserAuthenticator* user_authenticator, |
47 scoped_refptr<protocol::ConnectionToClient> connection, | 47 scoped_refptr<protocol::ConnectionToClient> connection, |
48 protocol::InputStub* input_stub, | 48 protocol::InputStub* input_stub, |
49 Capturer* capturer); | 49 Capturer* capturer); |
50 | 50 |
51 // protocol::HostStub interface. | 51 // protocol::HostStub interface. |
52 virtual void BeginSessionRequest( | 52 virtual void BeginSessionRequest( |
53 const protocol::LocalLoginCredentials* credentials, Task* done); | 53 const protocol::LocalLoginCredentials* credentials, |
| 54 const base::Closure& done); |
54 | 55 |
55 // protocol::InputStub interface. | 56 // protocol::InputStub interface. |
56 virtual void InjectKeyEvent(const protocol::KeyEvent& event); | 57 virtual void InjectKeyEvent(const protocol::KeyEvent& event); |
57 virtual void InjectMouseEvent(const protocol::MouseEvent& event); | 58 virtual void InjectMouseEvent(const protocol::MouseEvent& event); |
58 | 59 |
59 // Notifier called when the client is being disconnected. | 60 // Notifier called when the client is being disconnected. |
60 // This should only be called by ChromotingHost. | 61 // This should only be called by ChromotingHost. |
61 void OnDisconnected(); | 62 void OnDisconnected(); |
62 | 63 |
63 // Set the authenticated flag or log a failure message as appropriate. | 64 // Set the authenticated flag or log a failure message as appropriate. |
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
142 // Set of keys that are currently pressed down by the user. This is used so | 143 // Set of keys that are currently pressed down by the user. This is used so |
143 // we can release them if the user disconnects. | 144 // we can release them if the user disconnects. |
144 std::set<int> pressed_keys_; | 145 std::set<int> pressed_keys_; |
145 | 146 |
146 DISALLOW_COPY_AND_ASSIGN(ClientSession); | 147 DISALLOW_COPY_AND_ASSIGN(ClientSession); |
147 }; | 148 }; |
148 | 149 |
149 } // namespace remoting | 150 } // namespace remoting |
150 | 151 |
151 #endif // REMOTING_HOST_CLIENT_SESSION_H_ | 152 #endif // REMOTING_HOST_CLIENT_SESSION_H_ |
OLD | NEW |