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

Side by Side Diff: ui/events/ozone/evdev/device_event_dispatcher_evdev.h

Issue 1294523004: ozone: Handle pressure and tilt for stylus devices (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@new-pe-details
Patch Set: Address spang@ feedback Created 5 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 unified diff | Download patch
« no previous file with comments | « no previous file | ui/events/ozone/evdev/device_event_dispatcher_evdev.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 UI_EVENTS_OZONE_EVDEV_DEVICE_EVENT_DISPATCHER_H_ 5 #ifndef UI_EVENTS_OZONE_EVDEV_DEVICE_EVENT_DISPATCHER_H_
6 #define UI_EVENTS_OZONE_EVDEV_DEVICE_EVENT_DISPATCHER_H_ 6 #define UI_EVENTS_OZONE_EVDEV_DEVICE_EVENT_DISPATCHER_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/time/time.h" 10 #include "base/time/time.h"
(...skipping 20 matching lines...) Expand all
31 int device_id; 31 int device_id;
32 unsigned int code; 32 unsigned int code;
33 bool down; 33 bool down;
34 bool suppress_auto_repeat; 34 bool suppress_auto_repeat;
35 base::TimeDelta timestamp; 35 base::TimeDelta timestamp;
36 }; 36 };
37 37
38 struct EVENTS_OZONE_EVDEV_EXPORT MouseMoveEventParams { 38 struct EVENTS_OZONE_EVDEV_EXPORT MouseMoveEventParams {
39 MouseMoveEventParams(int device_id, 39 MouseMoveEventParams(int device_id,
40 const gfx::PointF& location, 40 const gfx::PointF& location,
41 EventPointerType pointer_type,
42 float force,
43 float tilt_x,
44 float tilt_y,
41 base::TimeDelta timestamp); 45 base::TimeDelta timestamp);
42 MouseMoveEventParams(const MouseMoveEventParams& other); 46 MouseMoveEventParams(const MouseMoveEventParams& other);
43 ~MouseMoveEventParams(); 47 ~MouseMoveEventParams();
44 48
45 int device_id; 49 int device_id;
46 gfx::PointF location; 50 gfx::PointF location;
51 EventPointerType pointer_type;
52 float force;
53 float tilt_x;
54 float tilt_y;
sadrul 2015/08/20 06:25:50 Is there a reason to not use PointerDetails for th
robert.bradford 2015/08/20 11:12:28 That's a great suggestion and i've implemented it.
47 base::TimeDelta timestamp; 55 base::TimeDelta timestamp;
48 }; 56 };
49 57
50 struct EVENTS_OZONE_EVDEV_EXPORT MouseButtonEventParams { 58 struct EVENTS_OZONE_EVDEV_EXPORT MouseButtonEventParams {
51 MouseButtonEventParams(int device_id, 59 MouseButtonEventParams(int device_id,
52 const gfx::PointF& location, 60 const gfx::PointF& location,
53 unsigned int button, 61 unsigned int button,
54 bool down, 62 bool down,
55 bool allow_remap, 63 bool allow_remap,
64 EventPointerType pointer_type,
65 float force,
66 float tilt_x,
67 float tilt_y,
56 base::TimeDelta timestamp); 68 base::TimeDelta timestamp);
57 MouseButtonEventParams(const MouseButtonEventParams& other); 69 MouseButtonEventParams(const MouseButtonEventParams& other);
58 ~MouseButtonEventParams(); 70 ~MouseButtonEventParams();
59 71
60 int device_id; 72 int device_id;
61 gfx::PointF location; 73 gfx::PointF location;
62 unsigned int button; 74 unsigned int button;
63 bool down; 75 bool down;
64 bool allow_remap; 76 bool allow_remap;
77 EventPointerType pointer_type;
78 float force;
79 float tilt_x;
80 float tilt_y;
65 base::TimeDelta timestamp; 81 base::TimeDelta timestamp;
66 }; 82 };
67 83
68 struct EVENTS_OZONE_EVDEV_EXPORT MouseWheelEventParams { 84 struct EVENTS_OZONE_EVDEV_EXPORT MouseWheelEventParams {
69 MouseWheelEventParams(int device_id, 85 MouseWheelEventParams(int device_id,
70 const gfx::PointF& location, 86 const gfx::PointF& location,
71 const gfx::Vector2d& delta, 87 const gfx::Vector2d& delta,
72 base::TimeDelta timestamp); 88 base::TimeDelta timestamp);
73 MouseWheelEventParams(const MouseWheelEventParams& other); 89 MouseWheelEventParams(const MouseWheelEventParams& other);
74 ~MouseWheelEventParams(); 90 ~MouseWheelEventParams();
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
142 virtual void DispatchMouseDevicesUpdated( 158 virtual void DispatchMouseDevicesUpdated(
143 const std::vector<InputDevice>& devices) = 0; 159 const std::vector<InputDevice>& devices) = 0;
144 virtual void DispatchTouchpadDevicesUpdated( 160 virtual void DispatchTouchpadDevicesUpdated(
145 const std::vector<InputDevice>& devices) = 0; 161 const std::vector<InputDevice>& devices) = 0;
146 virtual void DispatchDeviceListsComplete() = 0; 162 virtual void DispatchDeviceListsComplete() = 0;
147 }; 163 };
148 164
149 } // namespace ui 165 } // namespace ui
150 166
151 #endif // UI_EVENTS_OZONE_EVDEV_DEVICE_EVENT_DISPATCHER_H_ 167 #endif // UI_EVENTS_OZONE_EVDEV_DEVICE_EVENT_DISPATCHER_H_
OLDNEW
« no previous file with comments | « no previous file | ui/events/ozone/evdev/device_event_dispatcher_evdev.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698