1
0
mirror of https://github.com/FunkyFr3sh/cnc-ddraw.git synced 2025-03-24 17:49:52 +01:00

Fix Westwood Chat, should now work

This commit is contained in:
Toni Spets 2011-01-10 22:17:29 +02:00
parent 48bed3d6f1
commit e9bce8cdc1

6
main.c
View File

@ -276,6 +276,11 @@ LRESULT CALLBACK WndProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
{ {
ddraw_RestoreDisplayMode(ddraw); ddraw_RestoreDisplayMode(ddraw);
} }
/* disallow maximize, C&C does that when WCHAT DDE is used */
if(wParam == SIZE_MAXIMIZED)
{
ShowWindow(ddraw->hWnd, SW_RESTORE);
}
break; break;
case WM_NCACTIVATE: case WM_NCACTIVATE:
if(wParam == FALSE) if(wParam == FALSE)
@ -345,6 +350,7 @@ LRESULT CALLBACK WndProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
} }
lParam = MAKELPARAM(ddraw->cursor.x, ddraw->cursor.y); lParam = MAKELPARAM(ddraw->cursor.x, ddraw->cursor.y);
} }
case 1129: /* this somehow triggers network activity in C&C in WCHAT mode */
case 1139: /* this somehow triggers network activity in RA, investigate */ case 1139: /* this somehow triggers network activity in RA, investigate */
case 2024: /* this somehow allows RA edwin to work, investigate */ case 2024: /* this somehow allows RA edwin to work, investigate */
return ddraw->WndProc(hWnd, uMsg, wParam, lParam); return ddraw->WndProc(hWnd, uMsg, wParam, lParam);