Input: add touchpad speed, accel, and scroll settings

See #17265; adds speed and acceleration sliders, as well as a reverse
scroll option. Tested on a Dell XPS 15. Only affects touchpad prefs,
not mouse prefs

Also, fix issues where revert button wasn't being enabled sometimes
when it should have been.

Also, switch to using a BMessage to store touchpad settings in their
file.

(a previous version of this patch added only the scroll setting)

Change-Id: I4d5ed3fadfd5bae1f7b686c904959f6e168b84a0
Reviewed-on: https://review.haiku-os.org/c/haiku/+/8756
Tested-by: Commit checker robot <[email protected]>
Reviewed-by: John Scipione <[email protected]>
This commit is contained in:
PawanYr
2025-01-26 22:47:31 +00:00
committed by waddlesplash
parent 3e2f510808
commit c1b2086dfd
10 changed files with 216 additions and 74 deletions
+10 -2
View File
@@ -18,8 +18,13 @@ typedef struct {
uint8 scroll_acceleration; // from 0 to 20
uint8 tapgesture_sensibility; // 0 : no tapgesture
// 20: very light tip is enough (default)
// 20: very light tap is enough (default)
uint16 padblocker_threshold; //0 to 100
int32 trackpad_speed;
int32 trackpad_acceleration;
bool scroll_reverse;
} touchpad_settings;
@@ -32,7 +37,10 @@ const static touchpad_settings kDefaultTouchpadSettings = {
10,
10,
20,
30
30,
65536,
65536,
false
};
#define TOUCHPAD_SETTINGS_FILE "Touchpad_settings"