mirror of
https://codeberg.org/dnkl/foot.git
synced 2026-02-05 04:06:08 -05:00
input: implement wl_pointer::axis_value120()
This implements high resolution mouse wheel scroll events. A "normal" scroll step corresponds to the value 120. Anything less than that is a partial scroll step. This event replaces axis_discrete(), when we bind wl_seat v8 (which we now do, when available). We calculate the number of degrees that is required to scroll a single line, based off of the scrollback.multiplier value. Each high-res event accumulates, until we have at least the number of degress required to scroll one, or more lines. The remaining degrees are kept, and added to in the next scroll event. Closes #1738
This commit is contained in:
parent
f3d848da01
commit
aea16ba5d2
4 changed files with 69 additions and 13 deletions
|
|
@ -192,6 +192,7 @@ struct seat {
|
|||
|
||||
/* We used a discrete axis event in the current pointer frame */
|
||||
double aggregated[2];
|
||||
double aggregated_120[2];
|
||||
bool have_discrete;
|
||||
} mouse;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue