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

Unified Diff: content/common/input/input_param_traits.cc

Issue 942133002: Adding synthetic touch/mouse drag [Part2] (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@mousedrag
Patch Set: Fixing nit. Created 5 years, 10 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 | « no previous file | content/common/input_messages.h » ('j') | content/common/input_messages.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/common/input/input_param_traits.cc
diff --git a/content/common/input/input_param_traits.cc b/content/common/input/input_param_traits.cc
index 33769fe0b9833afdc559414a1294a6dd45547c41..1f4b7e4b1630a25d075de7b75e3d2a7c208cb6cc 100644
--- a/content/common/input/input_param_traits.cc
+++ b/content/common/input/input_param_traits.cc
@@ -6,6 +6,7 @@
#include "content/common/content_param_traits.h"
#include "content/common/input/synthetic_pinch_gesture_params.h"
+#include "content/common/input/synthetic_smooth_drag_gesture_params.h"
#include "content/common/input/synthetic_smooth_scroll_gesture_params.h"
#include "content/common/input/web_input_event_traits.h"
#include "content/common/input_messages.h"
@@ -62,6 +63,10 @@ void ParamTraits<content::SyntheticGesturePacket>::Write(Message* m,
WriteParam(m, *content::SyntheticSmoothScrollGestureParams::Cast(
p.gesture_params()));
break;
+ case content::SyntheticGestureParams::SMOOTH_DRAG_GESTURE:
+ WriteParam(m, *content::SyntheticSmoothDragGestureParams::Cast(
+ p.gesture_params()));
+ break;
case content::SyntheticGestureParams::PINCH_GESTURE:
WriteParam(m, *content::SyntheticPinchGestureParams::Cast(
p.gesture_params()));
@@ -70,10 +75,6 @@ void ParamTraits<content::SyntheticGesturePacket>::Write(Message* m,
WriteParam(m, *content::SyntheticTapGestureParams::Cast(
p.gesture_params()));
break;
- // TODO(ssid): When API and IPC messages are set up, implement this.
- case content::SyntheticGestureParams::SMOOTH_DRAG_GESTURE:
- NOTIMPLEMENTED();
- break;
}
}
@@ -90,6 +91,10 @@ bool ParamTraits<content::SyntheticGesturePacket>::Read(const Message* m,
ReadGestureParams<content::SyntheticSmoothScrollGestureParams>(m,
iter);
break;
+ case content::SyntheticGestureParams::SMOOTH_DRAG_GESTURE:
+ gesture_params =
+ ReadGestureParams<content::SyntheticSmoothDragGestureParams>(m, iter);
+ break;
case content::SyntheticGestureParams::PINCH_GESTURE:
gesture_params =
ReadGestureParams<content::SyntheticPinchGestureParams>(m, iter);
@@ -116,6 +121,11 @@ void ParamTraits<content::SyntheticGesturePacket>::Log(const param_type& p,
p.gesture_params()),
l);
break;
+ case content::SyntheticGestureParams::SMOOTH_DRAG_GESTURE:
+ LogParam(
+ *content::SyntheticSmoothDragGestureParams::Cast(p.gesture_params()),
+ l);
+ break;
case content::SyntheticGestureParams::PINCH_GESTURE:
LogParam(
*content::SyntheticPinchGestureParams::Cast(p.gesture_params()),
@@ -126,10 +136,6 @@ void ParamTraits<content::SyntheticGesturePacket>::Log(const param_type& p,
*content::SyntheticTapGestureParams::Cast(p.gesture_params()),
l);
break;
- // TODO(ssid): When API and IPC messages are set up, implement this.
- case content::SyntheticGestureParams::SMOOTH_DRAG_GESTURE:
- NOTIMPLEMENTED();
- break;
}
}
« no previous file with comments | « no previous file | content/common/input_messages.h » ('j') | content/common/input_messages.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698