From 97c0ca344ce01478b68b277e2ce34b0aef55f78b Mon Sep 17 00:00:00 2001 From: twinaphex <libretro@gmail.com> Date: Thu, 4 Sep 2014 19:15:24 +0200 Subject: [PATCH] (Menu) Refactor code to use menu_flush_stack_type --- frontend/menu/menu_common.c | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/frontend/menu/menu_common.c b/frontend/menu/menu_common.c index 1bb16da503..1fde59e840 100644 --- a/frontend/menu/menu_common.c +++ b/frontend/menu/menu_common.c @@ -446,16 +446,7 @@ bool menu_iterate(void) ret = driver.menu_ctx->input_postprocess(driver.menu->old_input_state); if (ret < 0) - { - unsigned type = 0; - file_list_get_last(driver.menu->menu_stack, &path, &label, &type); - - while (type != MENU_SETTINGS) - { - file_list_pop(driver.menu->menu_stack, &driver.menu->selection_ptr); - file_list_get_last(driver.menu->menu_stack, &path, &label, &type); - } - } + menu_flush_stack_type(driver.menu->menu_stack, MENU_SETTINGS); if (ret || input_entry_ret) return false;