mirror of
https://github.com/swaywm/sway.git
synced 2024-11-10 12:33:50 +01:00
seatop_down: Change type of sx, sy to double in begin_seatop_down
Losing the precision resulted in wlr_cursor and wlr_seat::pointer_state getting out of sync during pointer motion in seatop_down. Since the difference was always under 1 px, it was practically impossible to notice in normal use. But because of being out of sync, cursor_rebase would always end up incorrectly calling wlr_seat_pointer_notify_motion from seatop_default_begin (on releasing mouse button) which broke cursor locking. See #5405 Closes #4632
This commit is contained in:
parent
f4cda5157e
commit
d0fe721fbb
@ -239,7 +239,7 @@ enum wlr_edges find_resize_edge(struct sway_container *cont,
|
||||
void seatop_begin_default(struct sway_seat *seat);
|
||||
|
||||
void seatop_begin_down(struct sway_seat *seat, struct sway_container *con,
|
||||
uint32_t time_msec, int sx, int sy);
|
||||
uint32_t time_msec, double sx, double sy);
|
||||
|
||||
void seatop_begin_move_floating(struct sway_seat *seat,
|
||||
struct sway_container *con);
|
||||
|
@ -90,7 +90,7 @@ static const struct sway_seatop_impl seatop_impl = {
|
||||
};
|
||||
|
||||
void seatop_begin_down(struct sway_seat *seat, struct sway_container *con,
|
||||
uint32_t time_msec, int sx, int sy) {
|
||||
uint32_t time_msec, double sx, double sy) {
|
||||
seatop_end(seat);
|
||||
|
||||
struct seatop_down_event *e =
|
||||
|
Loading…
Reference in New Issue
Block a user