Add back reload-rom and close-rom

These commands have seemingly gotten lost somewhere
This commit is contained in:
Ilari Liusvaara 2015-04-11 04:37:39 +03:00
parent 71d649c487
commit c51cfe9099
2 changed files with 18 additions and 0 deletions

View file

@ -163,5 +163,13 @@
"flush-slotinfo":[ "flush-slotinfo":[
"flushslots", "Flush slotinfo cache", "flushslots", "Flush slotinfo cache",
{"":"Flush slotinfo cache"} {"":"Flush slotinfo cache"}
],
"reload-rom":[
"rlrom", "Reload the current ROM",
{"":"Reload the currently loaded ROM from disk"}
],
"close-rom":[
"clrom", "Close the current ROM",
{"":"Close the currentloy loaded ROM and return to null core"}
] ]
} }

View file

@ -561,6 +561,16 @@ namespace
mark_pending_save(args, SAVE_MOVIE, 0); mark_pending_save(args, SAVE_MOVIE, 0);
}); });
command::fnptr<> CMD_reload_rom(lsnes_cmds, CLOADSAVE::rlrom,
[]() throw(std::bad_alloc, std::runtime_error) {
reload_current_rom();
});
command::fnptr<> CMD_close_rom(lsnes_cmds, CLOADSAVE::clrom,
[]() throw(std::bad_alloc, std::runtime_error) {
close_rom();
});
command::fnptr<> CMD_set_rwmode(lsnes_cmds, "set-rwmode", "Switch to recording mode", command::fnptr<> CMD_set_rwmode(lsnes_cmds, "set-rwmode", "Switch to recording mode",
"Syntax: set-rwmode\nSwitches to recording mode\n", "Syntax: set-rwmode\nSwitches to recording mode\n",
[]() throw(std::bad_alloc, std::runtime_error) { []() throw(std::bad_alloc, std::runtime_error) {