Module: wine Branch: master Commit: fd4dbf0519c3b6126fdc906934d2eee5f825e32f URL: http://source.winehq.org/git/wine.git/?a=commit;h=fd4dbf0519c3b6126fdc906934...
Author: Piotr Caban piotr@codeweavers.com Date: Mon Dec 21 11:21:18 2015 +0100
winex11.drv: Call DragLeave instead of Drop if DROPEFFECT_NONE was set.
Signed-off-by: Piotr Caban piotr@codeweavers.com Signed-off-by: Alexandre Julliard julliard@winehq.org
---
dlls/winex11.drv/xdnd.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/dlls/winex11.drv/xdnd.c b/dlls/winex11.drv/xdnd.c index b066751..d5881ad 100644 --- a/dlls/winex11.drv/xdnd.c +++ b/dlls/winex11.drv/xdnd.c @@ -386,7 +386,7 @@ void X11DRV_XDND_DropEvent( HWND hWnd, XClientMessageEvent *event ) if (XDNDAccepted) { dropTarget = get_droptarget_pointer(XDNDLastDropTargetWnd); - if (dropTarget) + if (dropTarget && effect!=DROPEFFECT_NONE) { HRESULT hr; POINTL pointl; @@ -415,6 +415,13 @@ void X11DRV_XDND_DropEvent( HWND hWnd, XClientMessageEvent *event ) } IDropTarget_Release(dropTarget); } + else if (dropTarget) + { + HRESULT hr = IDropTarget_DragLeave(dropTarget); + if (FAILED(hr)) + WARN("IDropTarget_DragLeave failed, error 0x%08X\n", hr); + IDropTarget_Release(dropTarget); + } }
if (drop_file)