diff options
author | emersion <contact@emersion.fr> | 2019-02-28 19:22:47 +0100 |
---|---|---|
committer | Brian Ashworth <bosrsf04@gmail.com> | 2019-02-28 23:02:06 -0500 |
commit | 88b283c55713c45968e2df5f8b89a40a0b32f720 (patch) | |
tree | 4fad7681ca82cf833920731624ce9f52df709bc0 /sway/input/seat.c | |
parent | tray: fix pixmap colors (diff) | |
download | sway-88b283c55713c45968e2df5f8b89a40a0b32f720.tar.gz sway-88b283c55713c45968e2df5f8b89a40a0b32f720.tar.zst sway-88b283c55713c45968e2df5f8b89a40a0b32f720.zip |
seat: don't send button release when not pressed
All seat operations except "down" eat the button pressed event and don't send
it to clients. Thus, when ending such seat operations we shouldn't send the
button released event.
This commit moves the logic used to send pressed/released into the "down"
operation.
Diffstat (limited to 'sway/input/seat.c')
-rw-r--r-- | sway/input/seat.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sway/input/seat.c b/sway/input/seat.c index a16d3f27..9888ddfc 100644 --- a/sway/input/seat.c +++ b/sway/input/seat.c | |||
@@ -1211,9 +1211,9 @@ void seatop_motion(struct sway_seat *seat, uint32_t time_msec) { | |||
1211 | } | 1211 | } |
1212 | } | 1212 | } |
1213 | 1213 | ||
1214 | void seatop_finish(struct sway_seat *seat) { | 1214 | void seatop_finish(struct sway_seat *seat, uint32_t time_msec) { |
1215 | if (seat->seatop_impl && seat->seatop_impl->finish) { | 1215 | if (seat->seatop_impl && seat->seatop_impl->finish) { |
1216 | seat->seatop_impl->finish(seat); | 1216 | seat->seatop_impl->finish(seat, time_msec); |
1217 | } | 1217 | } |
1218 | free(seat->seatop_data); | 1218 | free(seat->seatop_data); |
1219 | seat->seatop_data = NULL; | 1219 | seat->seatop_data = NULL; |