1
0
mirror of https://github.com/FunkyFr3sh/cnc-ddraw.git synced 2025-03-15 14:14:47 +01:00

fix GetWindowRect

This commit is contained in:
FunkyFr3sh 2019-08-07 13:12:20 +02:00
parent 01ca7b739f
commit 636d133046
2 changed files with 8 additions and 3 deletions

View File

@ -3,8 +3,6 @@
#include <windows.h>
typedef HFONT(__stdcall* CREATEFONTINDIRECTA)(CONST LOGFONT*);
typedef BOOL (WINAPI* GETCURSORPOSPROC)(LPPOINT);
typedef BOOL(WINAPI* CLIPCURSORPROC)(const RECT*);
typedef int (WINAPI* SHOWCURSORPROC)(BOOL);

View File

@ -277,7 +277,14 @@ BOOL WINAPI fake_GetWindowRect(HWND hWnd, LPRECT lpRect)
}
else
{
return real_GetWindowRect(hWnd, lpRect) && MapWindowPoints(HWND_DESKTOP, ddraw->hWnd, (LPPOINT)lpRect, 2);
if (real_GetWindowRect(hWnd, lpRect))
{
MapWindowPoints(HWND_DESKTOP, ddraw->hWnd, (LPPOINT)lpRect, 2);
return TRUE;
}
return FALSE;
}
}