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

improve ClientToScreen and ScreenToClient hooks - fixes tiberian sun save game confirmation dialog

This commit is contained in:
FunkyFr3sh 2018-12-10 03:36:51 +01:00
parent 12119a40af
commit 133950f12d
2 changed files with 7 additions and 1 deletions

View File

@ -4,7 +4,7 @@
#define VERSION_MAJOR 1
#define VERSION_MINOR 3
#define VERSION_BUILD 3
#define VERSION_REVISION 0
#define VERSION_REVISION 2
#define VERSION VERSION_MAJOR, VERSION_MINOR, VERSION_BUILD, VERSION_REVISION
#define VERSION_STRING ver_str(VERSION_MAJOR, VERSION_MINOR, VERSION_BUILD, VERSION_REVISION)

View File

@ -362,11 +362,17 @@ BOOL WINAPI fake_GetClientRect(HWND hWnd, LPRECT lpRect)
BOOL WINAPI fake_ClientToScreen(HWND hWnd, LPPOINT lpPoint)
{
if (ddraw && ddraw->hWnd != hWnd)
return ClientToScreen(hWnd, lpPoint) && ScreenToClient(ddraw->hWnd, lpPoint);
return TRUE;
}
BOOL WINAPI fake_ScreenToClient(HWND hWnd, LPPOINT lpPoint)
{
if (ddraw && ddraw->hWnd != hWnd)
return ClientToScreen(ddraw->hWnd, lpPoint) && ScreenToClient(hWnd, lpPoint);
return TRUE;
}