Akihiro Sagawa : winemac.drv: Indicate whether the drop point is non-client area.
Module: wine Branch: master Commit: e54f1cf9fba1ae8748e8e5c577530138baaf9e3d URL: https://source.winehq.org/git/wine.git/?a=commit;h=e54f1cf9fba1ae8748e8e5c57... Author: Akihiro Sagawa <sagawa.aki(a)gmail.com> Date: Thu Aug 29 13:25:27 2019 -0500 winemac.drv: Indicate whether the drop point is non-client area. Signed-off-by: Akihiro Sagawa <sagawa.aki(a)gmail.com> Signed-off-by: Ken Thomases <ken(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/winemac.drv/dragdrop.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/dlls/winemac.drv/dragdrop.c b/dlls/winemac.drv/dragdrop.c index 7de50e5..a07b66a 100644 --- a/dlls/winemac.drv/dragdrop.c +++ b/dlls/winemac.drv/dragdrop.c @@ -453,9 +453,12 @@ BOOL query_drag_drop(macdrv_query* query) DROPFILES *dropfiles = GlobalLock(hdrop); if (dropfiles) { + RECT rect; dropfiles->pt.x = pt.x; dropfiles->pt.y = pt.y; - dropfiles->fNC = !ScreenToClient(hwnd, &dropfiles->pt); + dropfiles->fNC = !(ScreenToClient(hwnd, &dropfiles->pt) && + GetClientRect(hwnd, &rect) && + PtInRect(&rect, dropfiles->pt)); TRACE("sending WM_DROPFILES: hwnd %p nc %d pt %s %s\n", hwnd, dropfiles->fNC, wine_dbgstr_point(&dropfiles->pt),
participants (1)
-
Alexandre Julliard