From e665a18242a8cc098d1613fb98d6709178639ab6 Mon Sep 17 00:00:00 2001 From: Julian Orth Date: Sat, 2 Mar 2024 17:05:39 +0100 Subject: [PATCH] ipc: always send wl_data_source.drop_performed after the physical drop --- src/ifs/wl_seat/event_handling.rs | 3 --- src/ifs/wl_seat/pointer_owner.rs | 3 +++ 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/ifs/wl_seat/event_handling.rs b/src/ifs/wl_seat/event_handling.rs index 883db383..8ba365c4 100644 --- a/src/ifs/wl_seat/event_handling.rs +++ b/src/ifs/wl_seat/event_handling.rs @@ -808,9 +808,6 @@ impl WlSeatGlobal { dd.send_drop(); }) } - if let Some(src) = &dnd.src { - src.on_drop(); - } // surface.client.flush(); } diff --git a/src/ifs/wl_seat/pointer_owner.rs b/src/ifs/wl_seat/pointer_owner.rs index 3b796fe9..4bda97bc 100644 --- a/src/ifs/wl_seat/pointer_owner.rs +++ b/src/ifs/wl_seat/pointer_owner.rs @@ -421,6 +421,9 @@ impl PointerOwner for DndPointerOwner { if button != self.button || state != KeyState::Released { return; } + if let Some(src) = &self.dnd.src { + src.on_drop(); + } let should_drop = match &self.dnd.src { None => true, Some(s) => s.can_drop(),