OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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_EVENT_EXECUTOR_LINUX_H_ | 5 #ifndef REMOTING_HOST_EVENT_EXECUTOR_LINUX_H_ |
6 #define REMOTING_HOST_EVENT_EXECUTOR_LINUX_H_ | 6 #define REMOTING_HOST_EVENT_EXECUTOR_LINUX_H_ |
7 | 7 |
| 8 #include <vector> |
| 9 |
| 10 #include "base/task.h" |
| 11 #include "base/basictypes.h" |
8 #include "base/scoped_ptr.h" | 12 #include "base/scoped_ptr.h" |
9 #include "remoting/host/event_executor.h" | 13 #include "remoting/protocol/input_stub.h" |
| 14 |
| 15 class MessageLoop; |
10 | 16 |
11 namespace remoting { | 17 namespace remoting { |
12 | 18 |
| 19 class Capturer; |
| 20 class ChromotingClientMessage; |
13 class EventExecutorLinuxPimpl; | 21 class EventExecutorLinuxPimpl; |
14 | 22 |
15 // A class to generate events on Linux. | 23 // A class to generate events on Linux. |
16 class EventExecutorLinux : public EventExecutor { | 24 class EventExecutorLinux : public protocol::InputStub { |
17 public: | 25 public: |
18 EventExecutorLinux(Capturer* capturer); | 26 EventExecutorLinux(MessageLoop* message_loop, |
| 27 Capturer* capturer); |
19 virtual ~EventExecutorLinux(); | 28 virtual ~EventExecutorLinux(); |
20 | 29 |
21 virtual void HandleInputEvent(ChromotingClientMessage* message); | 30 virtual void InjectKeyEvent(const KeyEvent* event, Task* done); |
| 31 virtual void InjectMouseEvent(const MouseEvent* event, Task* done); |
22 | 32 |
23 private: | 33 private: |
| 34 MessageLoop* message_loop_; |
| 35 Capturer* capturer_; |
24 scoped_ptr<EventExecutorLinuxPimpl> pimpl_; | 36 scoped_ptr<EventExecutorLinuxPimpl> pimpl_; |
25 | 37 |
26 DISALLOW_COPY_AND_ASSIGN(EventExecutorLinux); | 38 DISALLOW_COPY_AND_ASSIGN(EventExecutorLinux); |
27 }; | 39 }; |
28 | 40 |
29 } // namespace remoting | 41 } // namespace remoting |
30 | 42 |
| 43 DISABLE_RUNNABLE_METHOD_REFCOUNT(remoting::EventExecutorLinux); |
| 44 |
31 #endif // REMOTING_HOST_EVENT_EXECUTOR_LINUX_H_ | 45 #endif // REMOTING_HOST_EVENT_EXECUTOR_LINUX_H_ |
OLD | NEW |