ENABLEMENU(rewindMemory != NULL && emulating));
ENABLEMENU(rewindMemory != NULL && emulating && rewindCount));
void updateToolsMenu(HMENU menu){  if(menu == NULL)    return;  EnableMenuItem(menu, ID_TOOLS_DISASSEMBLE,                 ENABLEMENU(videoOption <= VIDEO_4X));  EnableMenuItem(menu, ID_TOOLS_LOGGING,                 ENABLEMENU(videoOption <= VIDEO_4X));  EnableMenuItem(menu, ID_TOOLS_MAPVIEW,                 ENABLEMENU(videoOption <= VIDEO_4X));  EnableMenuItem(menu, ID_TOOLS_MEMORYVIEWER,                 ENABLEMENU(videoOption <= VIDEO_4X));  EnableMenuItem(menu, ID_TOOLS_PALETTEVIEW,                 ENABLEMENU(videoOption <= VIDEO_4X));  EnableMenuItem(menu, ID_TOOLS_OAMVIEWER,                 ENABLEMENU(videoOption <= VIDEO_4X));  EnableMenuItem(menu, ID_TOOLS_TILEVIEWER,                 ENABLEMENU(videoOption <= VIDEO_4X));  EnableMenuItem(menu, ID_TOOLS_CUSTOMIZE,                 ENABLEMENU(videoOption <= VIDEO_4X));    EnableMenuItem(menu, ID_TOOLS_DEBUG_GDB,                 ENABLEMENU(videoOption <= VIDEO_4X && remoteSocket == -1));  EnableMenuItem(menu, ID_TOOLS_DEBUG_LOADANDWAIT,                 ENABLEMENU(videoOption <= VIDEO_4X && remoteSocket == -1));  EnableMenuItem(menu, ID_TOOLS_DEBUG_DISCONNECT,                 ENABLEMENU(videoOption <= VIDEO_4X && remoteSocket != -1));  EnableMenuItem(menu, ID_TOOLS_DEBUG_BREAK,                 ENABLEMENU(videoOption <= VIDEO_4X && remoteSocket != -1));    EnableMenuItem(menu, ID_OPTIONS_SOUND_STARTRECORDING,                 ENABLEMENU(!soundRecording));  EnableMenuItem(menu, ID_OPTIONS_SOUND_STOPRECORDING,                 ENABLEMENU(soundRecording));  EnableMenuItem(menu, ID_TOOLS_RECORD_STARTAVIRECORDING,                 ENABLEMENU(!aviRecording));  EnableMenuItem(menu, ID_TOOLS_RECORD_STOPAVIRECORDING,                 ENABLEMENU(aviRecording));  EnableMenuItem(menu, ID_TOOLS_RECORD_STARTMOVIERECORDING,                 ENABLEMENU(!movieRecording));  EnableMenuItem(menu, ID_TOOLS_RECORD_STOPMOVIERECORDING,                 ENABLEMENU(movieRecording));  EnableMenuItem(menu, ID_TOOLS_PLAY_STARTMOVIEPLAYING,                 ENABLEMENU(emulating && !moviePlaying));  EnableMenuItem(menu, ID_TOOLS_PLAY_STOPMOVIEPLAYING,                 ENABLEMENU(emulating && moviePlaying));  EnableMenuItem(menu, ID_TOOLS_REWIND,                 ENABLEMENU(rewindMemory != NULL && emulating));}