diff --git a/menu/menu_input.c b/menu/menu_input.c index 2cbd91181c..79bf065ec5 100644 --- a/menu/menu_input.c +++ b/menu/menu_input.c @@ -940,6 +940,14 @@ void menu_input_post_iterate(int *ret, unsigned action) *ret |= menu_input_pointer_post_iterate(cbs, &entry, action); } +static const menu_ctx_driver_t *menu_ctx_driver_get_ptr(void) +{ + driver_t *driver = driver_get_ptr(); + if (!driver || !driver->menu_ctx) + return NULL; + return driver->menu_ctx; +} + unsigned menu_input_frame(retro_input_t input, retro_input_t trigger_input) { unsigned ret = 0; @@ -1029,6 +1037,13 @@ unsigned menu_input_frame(retro_input_t input, retro_input_t trigger_input) if (settings->menu.pointer.enable) menu_input_pointer(&ret); - - return ret; + + if (trigger_input && menu_ctx_driver_get_ptr()->perform_action && menu_ctx_driver_get_ptr()->perform_action(menu->userdata, ret)) + { + return MENU_ACTION_NOOP; + } + else + { + return ret; + } }