mirror of https://github.com/snes9xgit/snes9x.git
win32: only enable cheat if it was valid
This commit is contained in:
parent
42a2bc6e72
commit
b65b07112c
|
@ -10351,8 +10351,9 @@ INT_PTR CALLBACK DlgCheatSearchAdd(HWND hDlg, UINT msg, WPARAM wParam, LPARAM lP
|
||||||
code_string += code;
|
code_string += code;
|
||||||
}
|
}
|
||||||
|
|
||||||
S9xAddCheatGroup(new_cheat->name, code_string.c_str());
|
int index = S9xAddCheatGroup(new_cheat->name, code_string.c_str());
|
||||||
S9xEnableCheatGroup(Cheat.g.size() - 1);
|
if(index >= 0)
|
||||||
|
S9xEnableCheatGroup(index);
|
||||||
|
|
||||||
ret=0;
|
ret=0;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue