LCL-Gtk2: Ignore temporary windows (like dragging image) when selecting a target during Drag'n'Drop action. Patch by Alexander (Rouse_) Bagel, issue #40637.

This commit is contained in:
Maxim Ganetsky 2023-12-08 01:42:54 +03:00
parent 656d6ffc5d
commit e2c8faccd9

View File

@ -9828,6 +9828,9 @@ begin
@p.x, @p.y);
if window <> nil then
begin
// ignore temporary windows Hint/DragImageList/etc...
if gdk_window_get_type(Window) = GDK_WINDOW_TEMP then
Exit(LastWFPResult);
FillChar(ev{%H-}, SizeOf(ev), 0);
ev.any.window := Window;
Widget := gtk_get_event_widget(@ev);