OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_CONTROL_H_ | 5 #ifndef REMOTING_HOST_CLIENT_SESSION_CONTROL_H_ |
6 #define REMOTING_HOST_CLIENT_SESSION_CONTROL_H_ | 6 #define REMOTING_HOST_CLIENT_SESSION_CONTROL_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "remoting/host/mouse_move_observer.h" | |
10 #include "third_party/skia/include/core/SkPoint.h" | 9 #include "third_party/skia/include/core/SkPoint.h" |
11 | 10 |
12 namespace remoting { | 11 namespace remoting { |
13 | 12 |
14 // Allows the desktop environment to disconnect the client session and | 13 // Allows the desktop environment to disconnect the client session and |
15 // to control the remote input handling (i.e. disable, enable, and pause | 14 // to control the remote input handling (i.e. disable, enable, and pause |
16 // temporarily if the local mouse movements are detected). | 15 // temporarily if the local mouse movements are detected). |
17 // | 16 class ClientSessionControl { |
18 // TODO(alexeypa): remove the MouseMoveObserver interface entirely. | |
19 // See http://crbug.com/104544. | |
20 class ClientSessionControl : public MouseMoveObserver { | |
21 public: | 17 public: |
22 virtual ~ClientSessionControl() {} | 18 virtual ~ClientSessionControl() {} |
23 | 19 |
24 // Returns the authenticated JID of the client session. | 20 // Returns the authenticated JID of the client session. |
25 virtual const std::string& client_jid() const = 0; | 21 virtual const std::string& client_jid() const = 0; |
26 | 22 |
27 // Disconnects the client session, tears down transport resources and stops | 23 // Disconnects the client session, tears down transport resources and stops |
28 // scheduler components. | 24 // scheduler components. |
29 virtual void DisconnectSession() = 0; | 25 virtual void DisconnectSession() = 0; |
30 | 26 |
31 // Called when local mouse movement is detected. | 27 // Called when local mouse movement is detected. |
32 virtual void OnLocalMouseMoved(const SkIPoint& position) = 0; | 28 virtual void OnLocalMouseMoved(const SkIPoint& position) = 0; |
33 | 29 |
34 // Disables or enables the remote input in the client session. | 30 // Disables or enables the remote input in the client session. |
35 virtual void SetDisableInputs(bool disable_inputs) = 0; | 31 virtual void SetDisableInputs(bool disable_inputs) = 0; |
36 }; | 32 }; |
37 | 33 |
38 } // namespace remoting | 34 } // namespace remoting |
39 | 35 |
40 #endif // REMOTING_HOST_CLIENT_SESSION_CONTROL_H_ | 36 #endif // REMOTING_HOST_CLIENT_SESSION_CONTROL_H_ |
OLD | NEW |