Win32 - menu items added: Read only toggle, reload lua script, misc. Menu cleanup

This commit is contained in:
adelikat 2008-12-24 21:11:07 +00:00
parent c7c8ba8074
commit 8540908c8e
3 changed files with 33 additions and 20 deletions

View File

@ -49,9 +49,11 @@ BEGIN
POPUP "Movie"
BEGIN
MENUITEM "Record Movie...", MENU_RECORD_MOVIE
MENUITEM "Replay Movie...", MENU_REPLAY_MOVIE
MENUITEM "Play Movie...", MENU_REPLAY_MOVIE
MENUITEM "Stop Movie", MENU_STOP_MOVIE
MENUITEM "Play from beginning", ID_FILE_PLAYMOVIEFROMBEGINNING
MENUITEM SEPARATOR
MENUITEM "Read-only", ID_FILE_MOVIE_TOGGLEREAD
END
POPUP "Record AVI/Wav"
BEGIN
@ -67,6 +69,7 @@ BEGIN
BEGIN
MENUITEM "Run Lua Script...", ID_FILE_RUNLUASCRIPT
MENUITEM "Stop Lua Script", ID_FILE_STOPLUASCRIPT
MENUITEM "Reload Lua Script", ID_FILE_LUA_RELOADLUASCRIPT
END
MENUITEM SEPARATOR
MENUITEM "E&xit\tAlt+F4", MENU_EXIT
@ -331,8 +334,8 @@ BEGIN
END
POPUP "Game+NoMovie"
BEGIN
MENUITEM "&Replay Movie", FCEUX_CONTEXT_REPLAYMOVIE
MENUITEM "Record Movie", FCEUX_CONTEXT_RECORDMOVIE
MENUITEM "&Play Movie", FCEUX_CONTEXT_REPLAYMOVIE
MENUITEM "&Record Movie", FCEUX_CONTEXT_RECORDMOVIE
MENUITEM SEPARATOR
MENUITEM "Undo savestate", FCEUX_CONTEXT_UNDOSAVESTATE
MENUITEM "Undo loadstate", FCEUX_CONTEXT_UNDOLOADSTATE

View File

@ -642,6 +642,10 @@
#define ID_NOGAME_OPENMOSTRECENTROM 40327
#define FCEUX_CONTEXT_RECENTROM1 40328
#define ID_NES_EMULATION40329 40329
#define ID_MOVIE_TOGGLEREAD 40330
#define ID_FILE_MOVIE_TOGGLEREAD 40331
#define ID_LUA_RELOADLUASCRIPT 40332
#define ID_FILE_LUA_RELOADLUASCRIPT 40333
#define IDC_DEBUGGER_ICONTRAY 55535
#define MW_ValueLabel2 65423
#define MW_ValueLabel1 65426
@ -651,7 +655,7 @@
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 125
#define _APS_NEXT_COMMAND_VALUE 40330
#define _APS_NEXT_COMMAND_VALUE 40334
#define _APS_NEXT_CONTROL_VALUE 1199
#define _APS_NEXT_SYMED_VALUE 101
#endif

View File

@ -318,6 +318,9 @@ void UpdateCheckedMenuItems()
{
CheckMenuItem(fceumenu, polo2[x], *polo[x] ? MF_CHECKED : MF_UNCHECKED);
}
//File Maneu
CheckMenuItem(fceumenu, ID_FILE_MOVIE_TOGGLEREAD, movie_readonly ? MF_CHECKED : MF_UNCHECKED);
//NES Menu
CheckMenuItem(fceumenu, ID_NES_PAUSE, EmulationPaused ? MF_CHECKED : MF_UNCHECKED);
CheckMenuItem(fceumenu, ID_NES_TURBO, turbo ? MF_CHECKED : MF_UNCHECKED);
@ -972,6 +975,9 @@ LRESULT FAR PASCAL AppWndProc(HWND hWnd,UINT msg,WPARAM wParam,LPARAM lParam)
case ID_FILE_PLAYMOVIEFROMBEGINNING:
FCEUI_MoviePlayFromBeginning();
break;
case ID_FILE_MOVIE_TOGGLEREAD:
FCEUI_MovieToggleReadOnly();
break;
//Record Avi/Wav submenu
case MENU_RECORD_AVI:
@ -1000,6 +1006,9 @@ LRESULT FAR PASCAL AppWndProc(HWND hWnd,UINT msg,WPARAM wParam,LPARAM lParam)
case ID_FILE_STOPLUASCRIPT:
FCEU_LuaStop();
break;
case ID_FILE_LUA_RELOADLUASCRIPT:
FCEU_ReloadLuaCode();
break;
case MENU_EXIT:
DoFCEUExit();
@ -1044,10 +1053,7 @@ LRESULT FAR PASCAL AppWndProc(HWND hWnd,UINT msg,WPARAM wParam,LPARAM lParam)
case ID_NES_NORMALSPEED:
FCEUD_SetEmulationSpeed(2);
break;
case ID_NES_FASTESTSPEED:
FCEUD_SetEmulationSpeed(4);
break;
//Config Menu-----------------------------------------------------------
case MENU_HIDE_MENU:
ToggleHideMenu();
@ -1904,9 +1910,9 @@ void UpdateMenuHotkeys()
combined = "Record Movie...\t" + combo;
ChangeMenuItemText(MENU_RECORD_MOVIE, combined);
//Replay movie
//Play movie
combo = GetKeyComboName(FCEUD_CommandMapping[EMUCMD_MOVIE_REPLAY_FROM]);
combined = "Replay Movie...\t" + combo;
combined = "Play Movie...\t" + combo;
ChangeMenuItemText(MENU_REPLAY_MOVIE, combined);
//Stop movie
@ -1919,6 +1925,11 @@ void UpdateMenuHotkeys()
combined = "Play from beginning\t" + combo;
ChangeMenuItemText(ID_FILE_PLAYMOVIEFROMBEGINNING, combined);
//Read only
combo = GetKeyComboName(FCEUD_CommandMapping[EMUCMD_MOVIE_READONLY_TOGGLE]);
combined = "Read only\t" + combo;
ChangeMenuItemText(ID_FILE_MOVIE_TOGGLEREAD, combined);
//Screenshot
combo = GetKeyComboName(FCEUD_CommandMapping[EMUCMD_SCREENSHOT]);
combined = "Screenshot\t" + combo;
@ -1934,6 +1945,11 @@ void UpdateMenuHotkeys()
combined = "Stop AVI\t" + combo;
ChangeMenuItemText(MENU_STOP_AVI, combined);
//Reload Lua Script
combo = GetKeyComboName(FCEUD_CommandMapping[EMUCMD_SCRIPT_RELOAD]);
combined = "Reload Lua Script\t" + combo;
ChangeMenuItemText(ID_FILE_LUA_RELOADLUASCRIPT, combined);
//-------------------------------NES----------------------------------------
//Reset
combo = GetKeyComboName(FCEUD_CommandMapping[EMUCMD_RESET]);
@ -1965,11 +1981,6 @@ void UpdateMenuHotkeys()
combined = "Pause\t" + combo;
ChangeMenuItemText(ID_NES_PAUSE, combined);
//Frame Advance
combo = GetKeyComboName(FCEUD_CommandMapping[EMUCMD_FRAME_ADVANCE]);
combined = "Frame Advance\t" + combo;
ChangeMenuItemText(ID_NES_FRAMEADVANCE, combined);
//Turbo
combo = GetKeyComboName(FCEUD_CommandMapping[EMUCMD_SPEED_TURBO_TOGGLE]);
combined = "Turbo\t" + combo;
@ -1995,11 +2006,6 @@ void UpdateMenuHotkeys()
combined = "Normal Speed\t" + combo;
ChangeMenuItemText(ID_NES_NORMALSPEED, combined);
//Fastest Speed
combo = GetKeyComboName(FCEUD_CommandMapping[EMUCMD_SPEED_FASTEST]);
combined = "Fastest Speed\t" + combo;
ChangeMenuItemText(ID_NES_FASTESTSPEED, combined);
//-------------------------------Config-------------------------------------
//Hide Menu
combo = GetKeyComboName(FCEUD_CommandMapping[EMUCMD_HIDE_MENU_TOGGLE]);