diff options
author | InigoGutierrez <inigogf.95@gmail.com> | 2022-09-25 16:02:54 +0200 |
---|---|---|
committer | InigoGutierrez <inigogf.95@gmail.com> | 2022-09-25 16:02:54 +0200 |
commit | 6afdd9d74da250e47ac64d6690bd19d037045e99 (patch) | |
tree | 661f6cfb244c02bcd1fbfe8fb9b2bd9242a91394 /users/drashna/pointing/pointing.c | |
parent | 93a55e61b59d20f7cd842cce02e5b18a63a23612 (diff) | |
parent | 1bdf4cdc22ae57d111efb2f7d71e405e5c7b3f11 (diff) | |
download | qmk_firmware-6afdd9d74da250e47ac64d6690bd19d037045e99.tar.gz qmk_firmware-6afdd9d74da250e47ac64d6690bd19d037045e99.zip |
Merge branch 'master' into taamas
Diffstat (limited to 'users/drashna/pointing/pointing.c')
-rw-r--r-- | users/drashna/pointing/pointing.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/users/drashna/pointing/pointing.c b/users/drashna/pointing/pointing.c index 551034ff45..c9a7945a84 100644 --- a/users/drashna/pointing/pointing.c +++ b/users/drashna/pointing/pointing.c @@ -22,7 +22,7 @@ __attribute__((weak)) report_mouse_t pointing_device_task_keymap(report_mouse_t } report_mouse_t pointing_device_task_user(report_mouse_t mouse_report) { - int8_t x = mouse_report.x, y = mouse_report.y; + mouse_xy_report_t x = mouse_report.x, y = mouse_report.y; mouse_report.x = 0; mouse_report.y = 0; @@ -33,8 +33,8 @@ report_mouse_t pointing_device_task_user(report_mouse_t mouse_report) { #endif if (timer_elapsed(mouse_debounce_timer) > TAP_CHECK) { if (enable_acceleration) { - x = (x > 0 ? x * x / 16 + x : -x * x / 16 + x); - y = (y > 0 ? y * y / 16 + y : -y * y / 16 + y); + x = (mouse_xy_report_t)(x > 0 ? x * x / 16 + x : -x * x / 16 + x); + y = (mouse_xy_report_t)(y > 0 ? y * y / 16 + y : -y * y / 16 + y); } mouse_report.x = x; mouse_report.y = y; |