diff --git a/changelog.txt b/changelog.txt index 7f979ef6..325c3663 100644 --- a/changelog.txt +++ b/changelog.txt @@ -1,4 +1,5 @@ ---version 2.0.3 yet to be released--- +19-oct-2008 - shinydoofy - [ 2179829 ] user ability to toggle "bind savestates to movie" added for SDL, default hotkey F2 19-oct-2008 - adelikat - winew - added a toggle for binding savestates to movies 18-oct-2008 - adelikat - Win32 - added -cfg (config file) command line argument 08-oct-2008 - zeromus - SF [ 2073105 ] Laptop Volume Control keys make FCEUX go crazy and crash diff --git a/src/drivers/sdl/config.cpp b/src/drivers/sdl/config.cpp index 41941be7..248e2cf1 100644 --- a/src/drivers/sdl/config.cpp +++ b/src/drivers/sdl/config.cpp @@ -280,6 +280,7 @@ InitConfig() config->addOption(prefix + "IncreaseSpeed", SDLK_EQUALS); config->addOption(prefix + "FrameAdvance", SDLK_BACKSLASH); config->addOption(prefix + "Power", 0); + config->addOption(prefix + "BindState", SDLK_F2); diff --git a/src/drivers/sdl/input.cpp b/src/drivers/sdl/input.cpp index c52a5165..7b1eb0e5 100644 --- a/src/drivers/sdl/input.cpp +++ b/src/drivers/sdl/input.cpp @@ -35,6 +35,7 @@ #ifdef _S9XLUA_H #include "../../fceulua.h" #endif +#include "../../file.h" /** GLOBALS **/ @@ -375,6 +376,13 @@ KeyboardCommands() FCEU_LoadLuaCode(fname.c_str()); } #endif + + g_config->getOption("SDL.Hotkeys.BindState", &key); + if(_keyonly(key)) { + bindSavestate = !bindSavestate; + FCEUI_DispMessage("Savestate binding to movie %sabled.", + bindSavestate ? "en" : "dis"); + } // VS Unisystem games if(gametype == GIT_VSUNI) {