Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(472)

Unified Diff: remoting/client/plugin/chromoting_instance.cc

Issue 3175028: Add mouse event support to Chromoting client (Pepper and X11). (Closed)
Patch Set: Remove win float/int conversion Created 10 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « remoting/client/jingle_host_connection.cc ('k') | remoting/client/plugin/pepper_input_handler.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/client/plugin/chromoting_instance.cc
diff --git a/remoting/client/plugin/chromoting_instance.cc b/remoting/client/plugin/chromoting_instance.cc
index 6cbc51025723e95bb09fd17e4ac3c20ea497fe29..edde1f32e8b088eb71c837085c66f819c144c0cf 100644
--- a/remoting/client/plugin/chromoting_instance.cc
+++ b/remoting/client/plugin/chromoting_instance.cc
@@ -115,15 +115,23 @@ bool ChromotingInstance::CurrentlyOnPluginThread() const {
bool ChromotingInstance::HandleEvent(const PP_Event& event) {
DCHECK(CurrentlyOnPluginThread());
+ PepperInputHandler* pih
+ = static_cast<PepperInputHandler*>(input_handler_.get());
+
switch (event.type) {
case PP_EVENT_TYPE_MOUSEDOWN:
+ pih->HandleMouseButtonEvent(true, event.u.mouse);
+ break;
case PP_EVENT_TYPE_MOUSEUP:
+ pih->HandleMouseButtonEvent(false, event.u.mouse);
+ break;
case PP_EVENT_TYPE_MOUSEMOVE:
case PP_EVENT_TYPE_MOUSEENTER:
case PP_EVENT_TYPE_MOUSELEAVE:
- // client_->handle_mouse_event(npevent);
+ pih->HandleMouseMoveEvent(event.u.mouse);
break;
+ case PP_EVENT_TYPE_KEYDOWN:
case PP_EVENT_TYPE_CHAR:
// client_->handle_char_event(npevent);
break;
« no previous file with comments | « remoting/client/jingle_host_connection.cc ('k') | remoting/client/plugin/pepper_input_handler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698