Index: remoting/client/input_handler.cc |
diff --git a/remoting/client/input_handler.cc b/remoting/client/input_handler.cc |
index c203f54fb4962830e8b014a01d54280a4aaece3f..3eee9ef00c7b92ef6624005af3deb29087ebdc8d 100644 |
--- a/remoting/client/input_handler.cc |
+++ b/remoting/client/input_handler.cc |
@@ -23,7 +23,7 @@ InputHandler::InputHandler(ClientContext* context, |
void InputHandler::SendKeyEvent(bool press, int keycode) { |
protocol::InputStub* stub = connection_->input_stub(); |
- if (stub) { |
+ if (stub && stub->enabled()) { |
Wez
2011/03/04 12:09:38
Why does the InputStub and/or InputHandler even ex
garykac
2011/03/04 20:28:02
On host side: input_stub if part of the DesktopEnv
|
KeyEvent* event = new KeyEvent(); |
event->set_keycode(keycode); |
event->set_pressed(press); |
@@ -34,7 +34,7 @@ void InputHandler::SendKeyEvent(bool press, int keycode) { |
void InputHandler::SendMouseMoveEvent(int x, int y) { |
protocol::InputStub* stub = connection_->input_stub(); |
- if (stub) { |
+ if (stub && stub->enabled()) { |
MouseEvent* event = new MouseEvent(); |
event->set_x(x); |
event->set_y(y); |
@@ -46,7 +46,7 @@ void InputHandler::SendMouseMoveEvent(int x, int y) { |
void InputHandler::SendMouseButtonEvent(bool button_down, |
MouseEvent::MouseButton button) { |
protocol::InputStub* stub = connection_->input_stub(); |
- if (stub) { |
+ if (stub && stub->enabled()) { |
MouseEvent* event = new MouseEvent(); |
event->set_button(button); |
event->set_button_down(button_down); |