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_IT2ME_DESKTOP_ENVIRONMENT_H_ | 5 #ifndef REMOTING_HOST_IT2ME_DESKTOP_ENVIRONMENT_H_ |
6 #define REMOTING_HOST_IT2ME_DESKTOP_ENVIRONMENT_H_ | 6 #define REMOTING_HOST_IT2ME_DESKTOP_ENVIRONMENT_H_ |
7 | 7 |
8 #include "base/macros.h" | 8 #include "base/macros.h" |
9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
10 #include "base/memory/weak_ptr.h" | 10 #include "base/memory/weak_ptr.h" |
11 #include "remoting/host/basic_desktop_environment.h" | 11 #include "remoting/host/basic_desktop_environment.h" |
12 | 12 |
13 namespace remoting { | 13 namespace remoting { |
14 | 14 |
15 class HostWindow; | 15 class HostWindow; |
16 class LocalInputMonitor; | 16 class LocalInputMonitor; |
17 | 17 |
18 // Same as BasicDesktopEnvironment but also presents the Continue window to | 18 // Same as BasicDesktopEnvironment but also presents the Continue window to |
19 // the local user. | 19 // the local user. |
20 class It2MeDesktopEnvironment : public BasicDesktopEnvironment { | 20 class It2MeDesktopEnvironment : public BasicDesktopEnvironment { |
21 public: | 21 public: |
22 ~It2MeDesktopEnvironment() override; | 22 ~It2MeDesktopEnvironment() override; |
23 | 23 |
24 protected: | 24 protected: |
25 friend class It2MeDesktopEnvironmentFactory; | 25 friend class It2MeDesktopEnvironmentFactory; |
26 It2MeDesktopEnvironment( | 26 It2MeDesktopEnvironment( |
27 scoped_refptr<base::SingleThreadTaskRunner> caller_task_runner, | 27 scoped_refptr<base::SingleThreadTaskRunner> caller_task_runner, |
| 28 scoped_refptr<base::SingleThreadTaskRunner> video_capture_task_runner, |
28 scoped_refptr<base::SingleThreadTaskRunner> input_task_runner, | 29 scoped_refptr<base::SingleThreadTaskRunner> input_task_runner, |
29 scoped_refptr<base::SingleThreadTaskRunner> ui_task_runner, | 30 scoped_refptr<base::SingleThreadTaskRunner> ui_task_runner, |
30 base::WeakPtr<ClientSessionControl> client_session_control, | 31 base::WeakPtr<ClientSessionControl> client_session_control, |
31 bool supports_touch_events); | 32 bool supports_touch_events); |
32 | 33 |
33 private: | 34 private: |
34 // Presents the continue window to the local user. | 35 // Presents the continue window to the local user. |
35 scoped_ptr<HostWindow> continue_window_; | 36 scoped_ptr<HostWindow> continue_window_; |
36 | 37 |
37 // Presents the disconnect window to the local user. | 38 // Presents the disconnect window to the local user. |
38 scoped_ptr<HostWindow> disconnect_window_; | 39 scoped_ptr<HostWindow> disconnect_window_; |
39 | 40 |
40 // Notifies the client session about the local mouse movements. | 41 // Notifies the client session about the local mouse movements. |
41 scoped_ptr<LocalInputMonitor> local_input_monitor_; | 42 scoped_ptr<LocalInputMonitor> local_input_monitor_; |
42 | 43 |
43 DISALLOW_COPY_AND_ASSIGN(It2MeDesktopEnvironment); | 44 DISALLOW_COPY_AND_ASSIGN(It2MeDesktopEnvironment); |
44 }; | 45 }; |
45 | 46 |
46 // Used to create |It2MeDesktopEnvironment| instances. | 47 // Used to create |It2MeDesktopEnvironment| instances. |
47 class It2MeDesktopEnvironmentFactory : public BasicDesktopEnvironmentFactory { | 48 class It2MeDesktopEnvironmentFactory : public BasicDesktopEnvironmentFactory { |
48 public: | 49 public: |
49 It2MeDesktopEnvironmentFactory( | 50 It2MeDesktopEnvironmentFactory( |
50 scoped_refptr<base::SingleThreadTaskRunner> caller_task_runner, | 51 scoped_refptr<base::SingleThreadTaskRunner> caller_task_runner, |
| 52 scoped_refptr<base::SingleThreadTaskRunner> video_capture_task_runner, |
51 scoped_refptr<base::SingleThreadTaskRunner> input_task_runner, | 53 scoped_refptr<base::SingleThreadTaskRunner> input_task_runner, |
52 scoped_refptr<base::SingleThreadTaskRunner> ui_task_runner); | 54 scoped_refptr<base::SingleThreadTaskRunner> ui_task_runner); |
53 ~It2MeDesktopEnvironmentFactory() override; | 55 ~It2MeDesktopEnvironmentFactory() override; |
54 | 56 |
55 // DesktopEnvironmentFactory interface. | 57 // DesktopEnvironmentFactory interface. |
56 scoped_ptr<DesktopEnvironment> Create( | 58 scoped_ptr<DesktopEnvironment> Create( |
57 base::WeakPtr<ClientSessionControl> client_session_control) override; | 59 base::WeakPtr<ClientSessionControl> client_session_control) override; |
58 | 60 |
59 private: | 61 private: |
60 DISALLOW_COPY_AND_ASSIGN(It2MeDesktopEnvironmentFactory); | 62 DISALLOW_COPY_AND_ASSIGN(It2MeDesktopEnvironmentFactory); |
61 }; | 63 }; |
62 | 64 |
63 } // namespace remoting | 65 } // namespace remoting |
64 | 66 |
65 #endif // REMOTING_HOST_IT2ME_DESKTOP_ENVIRONMENT_H_ | 67 #endif // REMOTING_HOST_IT2ME_DESKTOP_ENVIRONMENT_H_ |
OLD | NEW |