diff options
author | Simon Thum <simon.thum@gmx.de> | 2011-02-23 02:29:33 +0100 |
---|---|---|
committer | Peter Hutterer <peter.hutterer@who-t.net> | 2011-03-02 14:47:58 +1000 |
commit | 8128846e16b406c7d459ae7556f7cd09bdc24c91 (patch) | |
tree | 311e1e77398b0c9bace281aaf5668b183b5c38db /include | |
parent | edcceedbd35df576929685767d0b619659e5b020 (diff) |
dix: refactor predictable scheme initialization
This intends to clean up the predictable accel struct
from purely scheme-related things like input properties,
as they would be useless in other use cases such
as wheel acceleration.
Signed-off-by: Simon Thum <simon.thum@gmx.de>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Diffstat (limited to 'include')
-rw-r--r-- | include/ptrveloc.h | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/include/ptrveloc.h b/include/ptrveloc.h index 8c59c0361..5c57d42e7 100644 --- a/include/ptrveloc.h +++ b/include/ptrveloc.h @@ -62,9 +62,6 @@ typedef struct _MotionTracker { int dir; /* initial direction bitfield */ } MotionTracker, *MotionTrackerPtr; -/* number of properties for predictable acceleration */ -#define NPROPS_PREDICTABLE_ACCEL 4 - /** * Contains all data needed to implement mouse ballistics */ @@ -91,9 +88,18 @@ typedef struct _DeviceVelocityRec { struct { /* to be able to query this information */ int profile_number; } statistics; - long prop_handlers[NPROPS_PREDICTABLE_ACCEL]; } DeviceVelocityRec, *DeviceVelocityPtr; +/** + * contains the run-time data for the predictable scheme, that is, a + * DeviceVelocityPtr and the property handlers. + */ +typedef struct _PredictableAccelSchemeRec { + DeviceVelocityPtr vel; + long* prop_handlers; + int num_prop_handlers; +} PredictableAccelSchemeRec, *PredictableAccelSchemePtr; + extern _X_EXPORT void InitVelocityData(DeviceVelocityPtr vel); |