summaryrefslogtreecommitdiffstatshomepage
path: root/src/emu/ui/cheatopt.cpp
diff options
context:
space:
mode:
author ImJezze <jezze@gmx.net>2016-02-22 18:29:53 +0100
committer ImJezze <jezze@gmx.net>2016-02-22 18:29:53 +0100
commitd44f8f4c2bdf19fdd55a45c779b746160d90d4fa (patch)
tree16d68eab6a3734ac0aaad0a6bc35e764a5a6fde9 /src/emu/ui/cheatopt.cpp
parent3be56e3cef6e7778c0ad5b7aac253e6da2876cd2 (diff)
parent72dd79838fc7b942cedc9099a9cffb01b3bb8637 (diff)
Merge pull request #13 from mamedev/master
Sync to base master
Diffstat (limited to 'src/emu/ui/cheatopt.cpp')
-rw-r--r--src/emu/ui/cheatopt.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/emu/ui/cheatopt.cpp b/src/emu/ui/cheatopt.cpp
index 1d13f8e8c94..6de3cb55936 100644
--- a/src/emu/ui/cheatopt.cpp
+++ b/src/emu/ui/cheatopt.cpp
@@ -34,16 +34,15 @@ void ui_menu_cheat::handle()
machine().popmessage(nullptr);
/* handle reset all + reset all cheats for reload all option */
- if (menu_event->itemref < ITEMREF_CHEATS_FIRST_ITEM && menu_event->iptkey == IPT_UI_SELECT)
+ if ((menu_event->itemref == ITEMREF_CHEATS_RESET_ALL || menu_event->itemref == ITEMREF_CHEATS_RELOAD_ALL) && menu_event->iptkey == IPT_UI_SELECT)
{
for (cheat_entry *curcheat = machine().cheat().first(); curcheat != nullptr; curcheat = curcheat->next())
if (curcheat->select_default_state())
changed = true;
}
-
/* handle individual cheats */
- else if (menu_event->itemref > ITEMREF_CHEATS_FIRST_ITEM)
+ else if (menu_event->itemref >= ITEMREF_CHEATS_FIRST_ITEM)
{
cheat_entry *curcheat = reinterpret_cast<cheat_entry *>(menu_event->itemref);
const char *string;