Don't set address in standalone game (should fix assertion

failure/possible crash); set default menu to Undo after it's been used
once.
This commit is contained in:
ehouse 2009-10-24 15:12:45 +00:00
parent 5602827ebf
commit 244e0f58db

View file

@ -916,8 +916,7 @@ ceInitAndStartBoard( CEAppGlobals* globals, XP_Bool newGame,
0, &globals->appPrefs.cp, &procs ); 0, &globals->appPrefs.cp, &procs );
#if defined XWFEATURE_RELAY || defined XWFEATURE_BLUETOOTH #if defined XWFEATURE_RELAY || defined XWFEATURE_BLUETOOTH
if ( !!addr ) { if ( !!addr && !!globals->game.comms ) {
XP_ASSERT( globals->game.comms != NULL );
comms_setAddr( globals->game.comms, addr ); comms_setAddr( globals->game.comms, addr );
} }
#endif #endif
@ -2558,6 +2557,7 @@ WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam)
case ID_MOVE_UNDOLAST: case ID_MOVE_UNDOLAST:
draw = server_handleUndo( globals->game.server ); draw = server_handleUndo( globals->game.server );
ceSetLeftSoftkey( globals, ID_MOVE_UNDOLAST );
break; break;
default: default: