From d78475372fa15bda4f5b18d9b3c91c6b81078986 Mon Sep 17 00:00:00 2001 From: Carlos Garnacho Date: Fri, 24 Nov 2023 23:37:20 +0100 Subject: [PATCH] gtk: Obey GTK grabs on DnD events Make DnD events get directed to the right places (and most importantly, not to the wrong places) when happening over modal parts of the UI. Fixes DnD started from popovers being able to drop on their modal toplevel. --- gtk/gtkmain.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gtk/gtkmain.c b/gtk/gtkmain.c index 1c5f27189b..ec252b7aa6 100644 --- a/gtk/gtkmain.c +++ b/gtk/gtkmain.c @@ -1696,7 +1696,7 @@ gtk_main_do_event (GdkEvent *event) { GdkDrop *drop = gdk_dnd_event_get_drop (event); gtk_drop_begin_event (drop, gdk_event_get_event_type (event)); - gtk_propagate_event (target_widget, event); + gtk_propagate_event (grab_widget, event); gtk_drop_end_event (drop); } break;