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

fix hidden cursor bug

This commit is contained in:
FunkyFr3sh 2019-03-17 01:42:47 +01:00
parent 4506b00863
commit 868a4479ba

View File

@ -1198,8 +1198,17 @@ LRESULT CALLBACK WndProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
HWND hWnd = FindWindowEx(HWND_DESKTOP, NULL, "SDlgDialog", NULL);
if (hWnd)
{
RECT rc;
if (GetWindowRect(hWnd, &rc) && (rc.bottom - rc.top != 479))
BOOL hideCursor = TRUE;
do
{
RECT rc;
if (GetWindowRect(hWnd, &rc) && rc.bottom - rc.top == 479)
hideCursor = FALSE;
} while ((hWnd = FindWindowEx(HWND_DESKTOP, hWnd, "SDlgDialog", NULL)));
if (hideCursor)
while (ShowCursor(FALSE) > 0);
}