(CocoaTouch) Use menu_displaylist_push

This commit is contained in:
Twinaphex 2015-05-13 16:54:47 +02:00
parent b48b2b81f4
commit 261b963702

View File

@ -772,10 +772,6 @@ didSelectRowAtIndexPath:(NSIndexPath *)indexPath
- (void)menuRefresh - (void)menuRefresh
{ {
menu_displaylist_info_t info = {0};
unsigned type = 0;
const char *path = NULL;
const char *label = NULL;
menu_handle_t *menu = menu_driver_get_ptr(); menu_handle_t *menu = menu_driver_get_ptr();
menu_list_t *menu_list = menu_list_get_ptr(); menu_list_t *menu_list = menu_list_get_ptr();
if (!menu || !menu_list) if (!menu || !menu_list)
@ -783,16 +779,7 @@ didSelectRowAtIndexPath:(NSIndexPath *)indexPath
if (!menu->need_refresh) if (!menu->need_refresh)
return; return;
menu_list_get_last_stack(menu->menu_list, &path, &label, &type); menu_displaylist_push(menu_list->selection_buf, menu_list->menu_stack);
info.list = menu_list->selection_buf;
info.menu_list = menu_list->menu_stack;
info.type = type;
strlcpy(info.path, path, sizeof(info.path));
strlcpy(info.label, label, sizeof(info.label));
menu_displaylist_deferred_push(&info);
menu->need_refresh = false;
} }
- (void)menuBack - (void)menuBack