| 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_CLIENT_INPUT_HANDLER_H_ | 5 #ifndef REMOTING_CLIENT_INPUT_HANDLER_H_ |
| 6 #define REMOTING_CLIENT_INPUT_HANDLER_H_ | 6 #define REMOTING_CLIENT_INPUT_HANDLER_H_ |
| 7 | 7 |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 #include "base/task.h" | 9 #include "base/task.h" |
| 10 #include "remoting/proto/event.pb.h" | 10 #include "remoting/proto/event.pb.h" |
| (...skipping 14 matching lines...) Expand all Loading... |
| 25 ChromotingView* view); | 25 ChromotingView* view); |
| 26 virtual ~InputHandler() {} | 26 virtual ~InputHandler() {} |
| 27 | 27 |
| 28 virtual void Initialize() = 0; | 28 virtual void Initialize() = 0; |
| 29 | 29 |
| 30 protected: | 30 protected: |
| 31 void SendKeyEvent(bool press, int keycode); | 31 void SendKeyEvent(bool press, int keycode); |
| 32 void SendMouseMoveEvent(int x, int y); | 32 void SendMouseMoveEvent(int x, int y); |
| 33 void SendMouseButtonEvent(bool down, | 33 void SendMouseButtonEvent(bool down, |
| 34 protocol::MouseEvent::MouseButton button); | 34 protocol::MouseEvent::MouseButton button); |
| 35 void SendMouseWheelEvent(int dx, int dy, int clicks_x, int clicks_y, |
| 36 bool page); |
| 35 | 37 |
| 36 ClientContext* context_; | 38 ClientContext* context_; |
| 37 protocol::ConnectionToHost* connection_; | 39 protocol::ConnectionToHost* connection_; |
| 38 ChromotingView* view_; | 40 ChromotingView* view_; |
| 39 | 41 |
| 40 private: | 42 private: |
| 41 DISALLOW_COPY_AND_ASSIGN(InputHandler); | 43 DISALLOW_COPY_AND_ASSIGN(InputHandler); |
| 42 }; | 44 }; |
| 43 | 45 |
| 44 } // namespace remoting | 46 } // namespace remoting |
| 45 | 47 |
| 46 DISABLE_RUNNABLE_METHOD_REFCOUNT(remoting::InputHandler); | 48 DISABLE_RUNNABLE_METHOD_REFCOUNT(remoting::InputHandler); |
| 47 | 49 |
| 48 #endif // REMOTING_CLIENT_INPUT_HANDLER_H_ | 50 #endif // REMOTING_CLIENT_INPUT_HANDLER_H_ |
| OLD | NEW |