Added patch to send WM_DROPFILES only when OLE dnd fails.

This commit is contained in:
Sebastian Lackner
2015-06-13 01:03:13 +02:00
parent 7765a19988
commit 7c2dfd1e28
5 changed files with 63 additions and 1 deletions

View File

@@ -270,6 +270,7 @@ patch_enable_all ()
enable_winepulse_PulseAudio_Support="$1"
enable_winex11_CandidateWindowPos="$1"
enable_winex11_Clipboard_HTML="$1"
enable_winex11_DragAndDrop="$1"
enable_winex11_Thread_Data="$1"
enable_winex11_Window_Groups="$1"
enable_winex11_Window_Style="$1"
@@ -888,6 +889,9 @@ patch_enable ()
winex11-Clipboard_HTML)
enable_winex11_Clipboard_HTML="$2"
;;
winex11-DragAndDrop)
enable_winex11_DragAndDrop="$2"
;;
winex11-Thread_Data)
enable_winex11_Thread_Data="$2"
;;
@@ -5652,6 +5656,21 @@ if test "$enable_winex11_Clipboard_HTML" -eq 1; then
) >> "$patchlist"
fi
# Patchset winex11-DragAndDrop
# |
# | This patchset fixes the following Wine bugs:
# | * [#29081] Only send WM_DROPFILES when OLE dnd fails
# |
# | Modified files:
# | * dlls/winex11.drv/xdnd.c
# |
if test "$enable_winex11_DragAndDrop" -eq 1; then
patch_apply winex11-DragAndDrop/0001-winex11.drv-Only-send-WM_DROPFILES-when-OLE-dnd-fail.patch
(
echo '+ { "Damjan Jovanovic", "winex11.drv: Only send WM_DROPFILES when OLE dnd fails.", 1 },';
) >> "$patchlist"
fi
# Patchset winex11-Thread_Data
# |
# | This patchset fixes the following Wine bugs:

View File

@@ -0,0 +1,40 @@
From f9febc3f5b77bb466f0173fbdb74d2a165038382 Mon Sep 17 00:00:00 2001
From: Damjan Jovanovic <damjan.jov@gmail.com>
Date: Sat, 13 Jun 2015 00:59:15 +0200
Subject: winex11.drv: Only send WM_DROPFILES when OLE dnd fails.
---
dlls/winex11.drv/xdnd.c | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/dlls/winex11.drv/xdnd.c b/dlls/winex11.drv/xdnd.c
index f6ce5e9..e660316 100644
--- a/dlls/winex11.drv/xdnd.c
+++ b/dlls/winex11.drv/xdnd.c
@@ -378,10 +378,6 @@ void X11DRV_XDND_DropEvent( HWND hWnd, XClientMessageEvent *event )
TRACE("\n");
- /* If we have a HDROP type we send a WM_ACCEPTFILES.*/
- if (GetWindowLongW( hWnd, GWL_EXSTYLE ) & WS_EX_ACCEPTFILES)
- X11DRV_XDND_SendDropFiles( hWnd );
-
/* Notify OLE of Drop */
dropTarget = get_droptarget_pointer(XDNDLastDropTargetWnd);
if (dropTarget)
@@ -407,6 +403,12 @@ void X11DRV_XDND_DropEvent( HWND hWnd, XClientMessageEvent *event )
WARN("drop failed, error 0x%08X\n", hr);
IDropTarget_Release(dropTarget);
}
+ else
+ {
+ /* If we have a HDROP type we send a WM_ACCEPTFILES.*/
+ if (GetWindowLongW( hWnd, GWL_EXSTYLE ) & WS_EX_ACCEPTFILES)
+ X11DRV_XDND_SendDropFiles( hWnd );
+ }
X11DRV_XDND_FreeDragDropOp();
--
2.4.2

View File

@@ -0,0 +1 @@
Fixes: [29081] Only send WM_DROPFILES when OLE dnd fails