summaryrefslogtreecommitdiffstats
path: root/remoting/host/event_executor_win.h
diff options
context:
space:
mode:
authorhclam@chromium.org <hclam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-11-16 19:53:35 +0000
committerhclam@chromium.org <hclam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-11-16 19:53:35 +0000
commit6fd3d6a1648a754d8023924074612d55c187b4cf (patch)
tree102ac605e52b8cf1a4e423b5403a0302a5ee9f76 /remoting/host/event_executor_win.h
parent3e4155c723ab73c8f754a82d81f0eb247c83536f (diff)
downloadchromium_src-6fd3d6a1648a754d8023924074612d55c187b4cf.zip
chromium_src-6fd3d6a1648a754d8023924074612d55c187b4cf.tar.gz
chromium_src-6fd3d6a1648a754d8023924074612d55c187b4cf.tar.bz2
Implement input stub in the host side for chromoting
Implement InputStub for the host. BUG=None TEST=None Review URL: http://codereview.chromium.org/4726003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@66314 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'remoting/host/event_executor_win.h')
-rw-r--r--remoting/host/event_executor_win.h37
1 files changed, 27 insertions, 10 deletions
diff --git a/remoting/host/event_executor_win.h b/remoting/host/event_executor_win.h
index e9a0269..b98d7be 100644
--- a/remoting/host/event_executor_win.h
+++ b/remoting/host/event_executor_win.h
@@ -7,29 +7,46 @@
#include <vector>
-#include "remoting/host/event_executor.h"
+#include "base/task.h"
+#include "base/basictypes.h"
+#include "base/scoped_ptr.h"
+#include "remoting/protocol/input_stub.h"
+
+class MessageLoop;
namespace remoting {
+class Capturer;
+class KeyEvent;
+class MouseDownEvent;
+class MouseSetPositionEvent;
+class MouseUpEvent;
+class MouseWheelEvent;
+
// A class to generate events on Windows.
-class EventExecutorWin : public EventExecutor {
+class EventExecutorWin : public protocol::InputStub {
public:
- EventExecutorWin(Capturer* capturer);
+ EventExecutorWin(MessageLoop* message_loop, Capturer* capturer);
virtual ~EventExecutorWin();
- virtual void HandleInputEvent(ChromotingClientMessage* message);
+ virtual void InjectKeyEvent(const KeyEvent* event, Task* done);
+ virtual void InjectMouseEvent(const MouseEvent* event, Task* done);
private:
- void HandleMouseSetPosition(ChromotingClientMessage* msg);
- void HandleMouseMove(ChromotingClientMessage* msg);
- void HandleMouseWheel(ChromotingClientMessage* msg);
- void HandleMouseButtonDown(ChromotingClientMessage* msg);
- void HandleMouseButtonUp(ChromotingClientMessage* msg);
- void HandleKey(ChromotingClientMessage* msg);
+ void HandleMouseSetPosition(const MouseSetPositionEvent& event);
+ void HandleMouseWheel(const MouseWheelEvent& event);
+ void HandleMouseButtonDown(const MouseDownEvent& event);
+ void HandleMouseButtonUp(const MouseUpEvent& event);
+ void HandleKey(const KeyEvent& event);
+
+ MessageLoop* message_loop_;
+ Capturer* capturer_;
DISALLOW_COPY_AND_ASSIGN(EventExecutorWin);
};
} // namespace remoting
+DISABLE_RUNNABLE_METHOD_REFCOUNT(remoting::EventExecutorWin);
+
#endif // REMOTING_HOST_EVENT_EXECUTOR_WIN_H_