Stop move grab when the start button is released
Browse files at this commitbd1fd8383c2cc4884cef194bf3ab3b239ec8f167Parent: aac54d01 changed file +2 -2
- src/input/move_grab.rs +2 -2
src/input/move_grab.rsmodified+2 -2
| @@ -123,8 +123,8 @@ impl PointerGrab<State> for MoveGrab { | ||
| 123 | 123 | } |
| 124 | 124 | } |
| 125 | 125 | |
| 126 | - if handle.current_pressed().is_empty() { | |
| 127 | - // No more buttons are pressed, release the grab. | |
| 126 | + if !handle.current_pressed().contains(&self.start_data.button) { | |
| 127 | + // The button that initiated the grab was released. | |
| 128 | 128 | handle.unset_grab(self, data, event.serial, event.time, true); |
| 129 | 129 | } |
| 130 | 130 | } |