# HG changeset patch # User Michael Pavone # Date 1502942668 25200 # Node ID 178de1432291285a537508ce1738e2862ea61e47 # Parent b9dbc823c014173154f8466ae71645e11a2b9e24 Using ui.exit to abort loading or saving a state via menu will no longer cause you to return to those sub-menus the next time the menu is loaded diff -r b9dbc823c014 -r 178de1432291 io.c --- a/io.c Wed Aug 16 20:45:51 2017 -0700 +++ b/io.c Wed Aug 16 21:04:28 2017 -0700 @@ -22,6 +22,7 @@ #include "sms.h" #include "render.h" #include "util.h" +#include "menu.h" #define CYCLE_NEVER 0xFFFFFFFF #define MIN_POLL_INTERVAL 6840 @@ -528,6 +529,14 @@ } case UI_EXIT: current_system->request_exit(current_system); + if (current_system->type == SYSTEM_GENESIS) { + genesis_context *gen = (genesis_context *)current_system; + if (gen->extra) { + //TODO: More robust mechanism for detecting menu + menu_context *menu = gen->extra; + menu->external_game_load = 1; + } + } break; } break;