BookmarkManager: Fix 'new folder text field size changes on clicking it' issue.
[chromium-blink-merge.git] / remoting / host / win / rdp_client.h
blob6761e9735f55ef8a8e6e055850ca4ec1cddf8993
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef REMOTING_HOST_WIN_RDP_CLIENT_H_
6 #define REMOTING_HOST_WIN_RDP_CLIENT_H_
8 #include <string>
10 #include "base/basictypes.h"
11 #include "base/memory/ref_counted.h"
12 #include "base/memory/scoped_ptr.h"
13 #include "base/threading/non_thread_safe.h"
15 namespace base {
16 class SingleThreadTaskRunner;
17 } // namespace base
19 namespace webrtc {
20 class DesktopSize;
21 } // namespace webrtc
23 namespace remoting {
25 // Establishes a loopback RDP connection to spawn a new Windows session.
26 class RdpClient : public base::NonThreadSafe {
27 public:
28 class EventHandler {
29 public:
30 virtual ~EventHandler() {}
32 // Notifies the event handler that an RDP connection has been established
33 // successfully.
34 virtual void OnRdpConnected() = 0;
36 // Notifies that the RDP connection has been closed.
37 virtual void OnRdpClosed() = 0;
40 RdpClient(
41 scoped_refptr<base::SingleThreadTaskRunner> caller_task_runner,
42 scoped_refptr<base::SingleThreadTaskRunner> ui_task_runner,
43 const webrtc::DesktopSize& screen_size,
44 const std::string& terminal_id,
45 EventHandler* event_handler);
46 virtual ~RdpClient();
48 // Sends Secure Attention Sequence to the session.
49 void InjectSas();
51 private:
52 // The actual implementation resides in Core class.
53 class Core;
54 scoped_refptr<Core> core_;
56 DISALLOW_COPY_AND_ASSIGN(RdpClient);
59 } // namespace remoting
61 #endif // REMOTING_HOST_WIN_RDP_CLIENT_H_