Skip to content

Instantly share code, notes, and snippets.

@hyperair
Created May 11, 2018 16:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hyperair/f65ac93c1a05431a4a497fb8425bb172 to your computer and use it in GitHub Desktop.
Save hyperair/f65ac93c1a05431a4a497fb8425bb172 to your computer and use it in GitHub Desktop.
diff --git a/src/evdev-fallback.c b/src/evdev-fallback.c
index 8a11c68..8bc009b 100644
--- a/src/evdev-fallback.c
+++ b/src/evdev-fallback.c
@@ -176,10 +176,6 @@ fallback_flush_relative_motion(struct fallback_dispatch *dispatch,
dispatch->rel.x = 0;
dispatch->rel.y = 0;
- /* Use unaccelerated deltas for pointing stick scroll */
- if (post_trackpoint_scroll(device, unaccel, time))
- return;
-
if (device->pointer.filter) {
/* Apply pointer acceleration. */
accel = filter_dispatch(device->pointer.filter,
@@ -192,6 +188,9 @@ fallback_flush_relative_motion(struct fallback_dispatch *dispatch,
accel = unaccel;
}
+ if (post_trackpoint_scroll(device, accel, time))
+ return;
+
if (normalized_is_zero(accel) && normalized_is_zero(unaccel))
return;
diff --git a/src/filter.c b/src/filter.c
index 206695b..be2e880 100644
--- a/src/filter.c
+++ b/src/filter.c
@@ -149,7 +149,7 @@ filter_get_type(struct motion_filter *filter)
/* Trackpoint acceleration */
#define TRACKPOINT_DEFAULT_MAX_ACCEL 2.0 /* in units/us */
-#define TRACKPOINT_DEFAULT_MAX_DELTA 60
+#define TRACKPOINT_DEFAULT_MAX_DELTA 120
/* As measured on a Lenovo T440 at kernel-default sensitivity 128 */
#define TRACKPOINT_DEFAULT_RANGE 20 /* max value */
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment