gtk2/gdk/win32
darkcutler 5b888393e5 Fix DnD on Windows
DnD under Windows needed 3 fixes to work with Gtk.DropTarget.

1. The droptarget_w32format_contentformat_map list never gets
filled so the gdk_win32_drop_read_async throws
"No compatible transfer format found".
This is an easy fix and done the same way in the win32 clipboard code.

2. After a drop no gdk_drop_emit_leave_event gets emitted.
This causes a second drop to trigger a bunch of assertion
'self->drop == drop' failed because the first drop is still active.
This is also an easy fix and done the same way by the macos backend.

3. Handling gdk_drop_status/gdk_drop_get_actions interaction.
In gtk_drop_target_do_drop the code
```gdk_drop_finish (self->drop, gdk_drop_get_actions (self->drop));```
calls the finish operation with the actions of the drop which triggers
```g_return_if_fail (gdk_drag_action_is_unique (action));```
in gdk_drop_finish. The code assumes that GdkDrop::actions gets
narrowed down by calling gdk_drop_status. This is hard to assure
because at the same time gdk_drop_get_actions is used by
gtk_drop_target_accept to figure out if a drag is accepted.
GdkDrop::actions serves a double purpose here as the supported source
actions and the currently agreed on action. Both the x11 and the
wayland backend get this wrong somewhat too. Under wayland/x11 when
a drag coming from a source that supports both MOVE and COPY is
first hovering a drop target that only supports COPY it is afterwards
no longer accepted by other drop targets only accepting MOVE.
Under x11 this is permanent for this drag but with wayland the drag
recovers when hovering other widgets. The win32 backend now sets the
supported source actions before any enter/move/drop and narrows them
down in gdk_win32_drop_status.

The patch only touches the win32 backend and fixes all three issues,
for me restoring DnD under windows.

Closes #4498
2022-07-29 14:44:26 +02:00
..
rc
gdkcairocontext-win32.c gdk: hdr => high depth 2021-10-06 22:50:07 +02:00
gdkcairocontext-win32.h
gdkclipboard-win32.c gdkclipboard-win32.c: Fix call to gdk_clipboard_claim_remote() 2022-04-01 10:28:37 +08:00
gdkclipboard-win32.h
gdkclipdrop-win32.c Fix last error reporting when calling GetClipboardOwner 2022-03-15 22:00:10 -04:00
gdkclipdrop-win32.h
gdkcursor-win32.c
gdkdevice-virtual.c
gdkdevice-virtual.h
gdkdevice-win32.c GdkWin32: Remove the global screen offset 2021-11-07 19:08:30 +01:00
gdkdevice-win32.h
gdkdevice-winpointer.c GdkWin32: Remove the global screen offset 2021-11-07 19:08:30 +01:00
gdkdevice-winpointer.h Initialize WinPointer and enumerate devices 2021-08-19 15:57:41 +02:00
gdkdevice-wintab.c GdkWin32: Remove the global screen offset 2021-11-07 19:08:30 +01:00
gdkdevice-wintab.h
gdkdevicemanager-win32.c win32: Don't include gdkinternals.h 2021-09-24 22:50:29 +02:00
gdkdevicemanager-win32.h Initialize WinPointer and enumerate devices 2021-08-19 15:57:41 +02:00
gdkdisplay-win32.c gdkdisplay-win32.c: Clean up GL initialization further 2022-01-19 11:56:32 +08:00
gdkdisplay-win32.h Cleanup "GDK/Win32: Try to fix initializing GLES contexts" 2022-01-19 11:56:32 +08:00
gdkdisplaymanager-win32.c win32: Don't include gdkinternals.h 2021-09-24 22:50:29 +02:00
gdkdrag-win32.c GdkWin32: Remove the global screen offset 2021-11-07 19:08:30 +01:00
gdkdrop-win32.c Fix DnD on Windows 2022-07-29 14:44:26 +02:00
gdkevents-win32.c GdkWin32: Generate crossing event after button release 2022-04-08 15:26:48 +02:00
gdkglcontext-win32-egl.c GDK-Win32: Realize EGL using common realization code 2021-11-08 15:40:49 +08:00
gdkglcontext-win32-wgl.c Cleanup "GDK/Win32: Try to fix initializing GLES contexts" 2022-01-19 11:56:32 +08:00
gdkglcontext-win32.c GDK-Win32: Drop GDK_WIN32_ENABLE_EGL flag 2021-11-08 15:25:24 +08:00
gdkglcontext-win32.h GDK-Win32: Drop GDK_WIN32_ENABLE_EGL flag 2021-11-08 15:25:24 +08:00
gdkglobals-win32.c GdkWin32: Remove _gdk_input_codepage variable 2022-01-17 14:14:55 +01:00
gdkhdataoutputstream-win32.c GDK/Win32: Use lowercase windows.h 2021-09-26 21:52:12 +08:00
gdkhdataoutputstream-win32.h
gdkinput-winpointer.c GDK-Win32: Fix build 2021-09-30 16:21:38 +08:00
gdkinput-winpointer.h Handle WinPointer input 2021-08-19 15:57:41 +02:00
gdkkeys-win32-impl-wow64.c Rewrite GdkWin32Keymap (load table directly from layout DLL) 2022-01-12 19:01:35 +01:00
gdkkeys-win32-impl.c gdkkeys-win32: Also ignore Ctrl + Shift (etc.) 2022-02-09 10:43:07 +01:00
gdkkeys-win32.c gdkkeys-win32: Only perform substitution as last-resort 2022-03-03 09:59:53 +01:00
gdkkeys-win32.h gdkkeys-win32: Fix capslock handling 2022-01-12 21:43:53 +01:00
gdkmain-win32.c GdkWin32: Remove _gdk_input_codepage variable 2022-01-17 14:14:55 +01:00
gdkmonitor-win32.c GdkWin32: Remove the global screen offset 2021-11-07 19:08:30 +01:00
gdkmonitor-win32.h
gdkprivate-win32.h GdkWin32: Remove _gdk_input_codepage variable 2022-01-17 14:14:55 +01:00
gdkproperty-win32.c
gdkscreen-win32.c Raise _WIN32_WINNT macro to target Windows 7 API 2021-08-19 15:57:33 +02:00
gdksurface-win32.c GdkWin32: Configure as needed when going fullscreen 2022-03-03 10:01:41 +01:00
gdksurface-win32.h GDK-Win32: Make surface ready for updates 2021-12-01 17:32:40 +08:00
gdkvulkancontext-win32.c gdk: hdr => high depth 2021-10-06 22:50:07 +02:00
gdkvulkancontext-win32.h
gdkwin32.h
gdkwin32cursor.h GDK/Win32: Use lowercase windows.h 2021-09-26 21:52:12 +08:00
gdkwin32display.h
gdkwin32displaymanager.h
gdkwin32dnd-private.h win32: Don't include gdkinternals.h 2021-09-24 22:50:29 +02:00
gdkwin32dnd.h
gdkwin32glcontext.h
gdkwin32id.c
gdkwin32keys.h
gdkwin32langnotification.c
gdkwin32langnotification.h
gdkwin32misc.h
gdkwin32monitor.h
gdkwin32screen.h
gdkwin32surface.h
meson.build Rewrite GdkWin32Keymap (load table directly from layout DLL) 2022-01-12 19:01:35 +01:00
pktdef.h
winpointer.h Add winpointer.h header file for type declarations 2021-08-19 15:57:39 +02:00
wintab.h
xcursors.h