winex11.drv: Indicate whether the drop point is non-client area.
Signed-off-by: Akihiro Sagawa <sagawa.aki@gmail.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
424e1e71ca
commit
aaac4e25ab
|
@ -636,12 +636,15 @@ static HRESULT X11DRV_XDND_SendDropFiles(HWND hwnd)
|
||||||
HGLOBAL dropHandle = GlobalAlloc(GMEM_FIXED, GlobalSize(current->contents));
|
HGLOBAL dropHandle = GlobalAlloc(GMEM_FIXED, GlobalSize(current->contents));
|
||||||
if (dropHandle)
|
if (dropHandle)
|
||||||
{
|
{
|
||||||
|
RECT rect;
|
||||||
DROPFILES *lpDrop = GlobalLock(dropHandle);
|
DROPFILES *lpDrop = GlobalLock(dropHandle);
|
||||||
memcpy(lpDrop, GlobalLock(current->contents), GlobalSize(current->contents));
|
memcpy(lpDrop, GlobalLock(current->contents), GlobalSize(current->contents));
|
||||||
GlobalUnlock(current->contents);
|
GlobalUnlock(current->contents);
|
||||||
lpDrop->pt.x = XDNDxy.x;
|
lpDrop->pt.x = XDNDxy.x;
|
||||||
lpDrop->pt.y = XDNDxy.y;
|
lpDrop->pt.y = XDNDxy.y;
|
||||||
lpDrop->fNC = !ScreenToClient(hwnd, &lpDrop->pt);
|
lpDrop->fNC = !(ScreenToClient(hwnd, &lpDrop->pt) &&
|
||||||
|
GetClientRect(hwnd, &rect) &&
|
||||||
|
PtInRect(&rect, lpDrop->pt));
|
||||||
TRACE("Sending WM_DROPFILES: hWnd=0x%p, fNC=%d, x=%d, y=%d, files=%p(%s)\n", hwnd,
|
TRACE("Sending WM_DROPFILES: hWnd=0x%p, fNC=%d, x=%d, y=%d, files=%p(%s)\n", hwnd,
|
||||||
lpDrop->fNC, lpDrop->pt.x, lpDrop->pt.y, ((char*)lpDrop) + lpDrop->pFiles,
|
lpDrop->fNC, lpDrop->pt.x, lpDrop->pt.y, ((char*)lpDrop) + lpDrop->pFiles,
|
||||||
debugstr_w((WCHAR*)(((char*)lpDrop) + lpDrop->pFiles)));
|
debugstr_w((WCHAR*)(((char*)lpDrop) + lpDrop->pFiles)));
|
||||||
|
|
Loading…
Reference in New Issue