mirror of
https://gitlab.freedesktop.org/libinput/libinput.git
synced 2026-01-09 14:30:17 +01:00
tablet: don't use absinfo_range for the percentage calculation
Our percents are inclusive 0% and 100%.
This commit is contained in:
parent
0322403ea4
commit
7cffd28e8f
1 changed files with 1 additions and 1 deletions
|
|
@ -1073,7 +1073,7 @@ tool_set_bits(const struct tablet_dispatch *tablet,
|
|||
static inline int
|
||||
axis_range_percentage(const struct input_absinfo *a, double percent)
|
||||
{
|
||||
return absinfo_range(a) * percent/100.0 + a->minimum;
|
||||
return (a->maximum - a->minimum) * percent/100.0 + a->minimum;
|
||||
}
|
||||
|
||||
static inline void
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue