fix DnD crash: do not double-deliver button events during drag
When a drag grab is active, wlroots internally handles button events via the grab mechanism. Calling wlr_seat_pointer_notify_button manually during a drag double-delivers the release, causing an assertion in wlr_data_source_destroy.
This commit is contained in:
parent
467805da20
commit
ce696a72a0
|
|
@ -331,11 +331,6 @@ handle_pointer_button(struct wl_listener *listener, void *data)
|
|||
wlr_seat_pointer_notify_button(wl_state.seat, ev->time_msec,
|
||||
ev->button, ev->state);
|
||||
wlr_seat_pointer_notify_frame(wl_state.seat);
|
||||
} else if (wl_state.seat->drag) {
|
||||
/* Active drag grab: always forward so wlroots can end the drag. */
|
||||
wlr_seat_pointer_notify_button(wl_state.seat, ev->time_msec,
|
||||
ev->button, ev->state);
|
||||
wlr_seat_pointer_notify_frame(wl_state.seat);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue