summaryrefslogtreecommitdiff
path: root/plugins/dfinput/cfg.c
diff options
context:
space:
mode:
authorSND\ckain_cp <SND\ckain_cp@e17a0e51-4ae3-4d35-97c3-1a29b211df97>2014-01-24 13:59:46 +0000
committerSND\ckain_cp <SND\ckain_cp@e17a0e51-4ae3-4d35-97c3-1a29b211df97>2014-01-24 13:59:46 +0000
commite1108dba69ad14fed7bc64f996ea09342c900a81 (patch)
treea3798c4031cce49eeb5964ec9ae49a9627bc5a91 /plugins/dfinput/cfg.c
parent47b0777b946e413500bc0420d91298aa4e8f8301 (diff)
downloadpcsxr-e1108dba69ad14fed7bc64f996ea09342c900a81.tar.gz
Added rewind feature. Currently only supported via GTK and needs SHM. Rewind save state depth is configured via RewindCount config param. Recommended value is 200 or so -> uses less than 1G of memory
git-svn-id: https://pcsxr.svn.codeplex.com/svn/pcsxr@88433 e17a0e51-4ae3-4d35-97c3-1a29b211df97
Diffstat (limited to 'plugins/dfinput/cfg.c')
-rwxr-xr-xplugins/dfinput/cfg.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/plugins/dfinput/cfg.c b/plugins/dfinput/cfg.c
index 6e45a122..2757bd74 100755
--- a/plugins/dfinput/cfg.c
+++ b/plugins/dfinput/cfg.c
@@ -125,6 +125,7 @@ static void SetDefaultConfig() {
g.cfg.E.EmuDef[EMU_INCREMENTSTATE].EmuKeyEvent = XK_F2;
g.cfg.E.EmuDef[EMU_SCREENSHOT].EmuKeyEvent = XK_F8;
g.cfg.E.EmuDef[EMU_ESCAPE].EmuKeyEvent = XK_Escape;
+ g.cfg.E.EmuDef[EMU_REWIND].EmuKeyEvent = XK_BackSpace;
}
void LoadPADConfig() {
@@ -193,6 +194,11 @@ void LoadPADConfig() {
g.cfg.E.EmuDef[EMU_ESCAPE].Mapping.Key = a;
g.cfg.E.EmuDef[EMU_ESCAPE].Mapping.JoyEvType = b;
g.cfg.E.EmuDef[EMU_ESCAPE].Mapping.J.d = c;
+ } else if (strncmp(buf, "EMU_REWIND=", 11) == 0) {
+ sscanf(buf, "EMU_REWIND=%d,%d,%d", &a, &b, &c);
+ g.cfg.E.EmuDef[EMU_REWIND].Mapping.Key = a;
+ g.cfg.E.EmuDef[EMU_REWIND].Mapping.JoyEvType = b;
+ g.cfg.E.EmuDef[EMU_REWIND].Mapping.J.d = c;
} else if (strncmp(buf, "Select=", 7) == 0) {
sscanf(buf, "Select=%d,%d,%d", &a, &b, &c);
g.cfg.PadDef[current].KeyDef[DKEY_SELECT].Key = a;
@@ -428,5 +434,8 @@ void SavePADConfig() {
fprintf(fp, "EMU_ESCAPE=%d,%d,%d\n", g.cfg.E.EmuDef[EMU_ESCAPE].Mapping.Key,
g.cfg.E.EmuDef[EMU_ESCAPE].Mapping.JoyEvType,
g.cfg.E.EmuDef[EMU_ESCAPE].Mapping.J.d);
+ fprintf(fp, "EMU_REWIND=%d,%d,%d\n", g.cfg.E.EmuDef[EMU_REWIND].Mapping.Key,
+ g.cfg.E.EmuDef[EMU_REWIND].Mapping.JoyEvType,
+ g.cfg.E.EmuDef[EMU_REWIND].Mapping.J.d);
fclose(fp);
}