mirror of
https://github.com/libretro/RetroArch
synced 2025-01-31 15:32:59 +00:00
Merge pull request #1404 from lakkatv/xmb
(Menu) remove unused callback in the menu driver
This commit is contained in:
commit
aba3ae1898
@ -631,14 +631,11 @@ menu_ctx_driver_t menu_ctx_glui = {
|
||||
NULL,
|
||||
glui_frame,
|
||||
glui_init,
|
||||
NULL,
|
||||
glui_free,
|
||||
glui_context_reset,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
glui_navigation_clear,
|
||||
NULL,
|
||||
NULL,
|
||||
|
@ -95,13 +95,10 @@ menu_ctx_driver_t menu_ctx_ios = {
|
||||
NULL, // render
|
||||
NULL, // frame
|
||||
ios_init, // init
|
||||
NULL, // init_lists
|
||||
ios_free, // free
|
||||
NULL, // context_reset
|
||||
NULL, // context_destroy
|
||||
NULL, // populate_entries
|
||||
NULL, // iterate
|
||||
NULL, // input_postprocess
|
||||
NULL, // toggle
|
||||
NULL, // navigation_clear
|
||||
NULL, // navigation_decrement
|
||||
|
@ -660,14 +660,11 @@ menu_ctx_driver_t menu_ctx_rgui = {
|
||||
rgui_render,
|
||||
NULL,
|
||||
rgui_init,
|
||||
NULL,
|
||||
rgui_free,
|
||||
NULL,
|
||||
NULL,
|
||||
rgui_populate_entries,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
rgui_navigation_clear,
|
||||
NULL,
|
||||
NULL,
|
||||
|
@ -373,7 +373,6 @@ menu_ctx_driver_t menu_ctx_rmenu = {
|
||||
rmenu_render,
|
||||
NULL,
|
||||
rmenu_init,
|
||||
NULL,
|
||||
rmenu_free,
|
||||
rmenu_context_reset,
|
||||
rmenu_context_destroy,
|
||||
@ -391,8 +390,6 @@ menu_ctx_driver_t menu_ctx_rmenu = {
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
rmenu_entry_iterate,
|
||||
"rmenu",
|
||||
};
|
||||
|
@ -694,13 +694,10 @@ menu_ctx_driver_t menu_ctx_rmenu_xui = {
|
||||
rmenu_xui_render,
|
||||
rmenu_xui_frame,
|
||||
rmenu_xui_init,
|
||||
NULL,
|
||||
rmenu_xui_free,
|
||||
NULL,
|
||||
NULL,
|
||||
rmenu_xui_populate_entries,
|
||||
NULL,
|
||||
NULL,
|
||||
rmenu_xui_navigation_clear,
|
||||
rmenu_xui_navigation_set_visible,
|
||||
rmenu_xui_navigation_set_visible,
|
||||
|
@ -1698,13 +1698,10 @@ menu_ctx_driver_t menu_ctx_xmb = {
|
||||
NULL,
|
||||
xmb_frame,
|
||||
xmb_init,
|
||||
NULL,
|
||||
xmb_free,
|
||||
xmb_context_reset,
|
||||
xmb_context_destroy,
|
||||
xmb_populate_entries,
|
||||
NULL,
|
||||
NULL,
|
||||
xmb_toggle,
|
||||
xmb_navigation_clear,
|
||||
xmb_navigation_decrement,
|
||||
|
29
menu/menu.c
29
menu/menu.c
@ -215,32 +215,6 @@ void menu_free_list(void *data)
|
||||
menu->list_settings = NULL;
|
||||
}
|
||||
|
||||
/**
|
||||
* menu_init_list:
|
||||
* @data : Menu handle.
|
||||
*
|
||||
* Initialize menu lists.
|
||||
* Will be performed after menu_init().
|
||||
*
|
||||
* Returns: true (1) if successful, otherwise false (0).
|
||||
**/
|
||||
bool menu_init_list(void *data)
|
||||
{
|
||||
menu_handle_t *menu = (menu_handle_t*)data;
|
||||
|
||||
if (!menu)
|
||||
return false;
|
||||
|
||||
if (!menu_entries_init(menu))
|
||||
return false;
|
||||
|
||||
if (driver.menu_ctx && driver.menu_ctx->init_lists)
|
||||
if (!(driver.menu_ctx->init_lists(menu)))
|
||||
return false;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* menu_free:
|
||||
* @info : Menu handle.
|
||||
@ -432,9 +406,6 @@ int menu_iterate(retro_input_t input,
|
||||
if (g_settings.menu.throttle && (g_settings.menu.pause_libretro || !g_extern.content_is_init))
|
||||
draw_frame();
|
||||
|
||||
if (driver.menu_ctx && driver.menu_ctx->input_postprocess)
|
||||
driver.menu_ctx->input_postprocess(input, old_input);
|
||||
|
||||
if (ret)
|
||||
return -1;
|
||||
|
||||
|
11
menu/menu.h
11
menu/menu.h
@ -155,17 +155,6 @@ void *menu_init(const void *data);
|
||||
**/
|
||||
void menu_free_list(void *data);
|
||||
|
||||
/**
|
||||
* menu_init_list:
|
||||
* @data : Menu handle.
|
||||
*
|
||||
* Initialize menu lists.
|
||||
* Will be performed after menu_init().
|
||||
*
|
||||
* Returns: true (1) if successful, otherwise false (0).
|
||||
**/
|
||||
bool menu_init_list(void *data);
|
||||
|
||||
/**
|
||||
* menu_iterate:
|
||||
* @input : input sample for this frame
|
||||
|
@ -18,6 +18,7 @@
|
||||
#include <string/string_list.h>
|
||||
#include "menu_driver.h"
|
||||
#include "menu.h"
|
||||
#include "menu_entries.h"
|
||||
#include "../driver.h"
|
||||
#include "../general.h"
|
||||
|
||||
@ -153,7 +154,7 @@ void init_menu(void)
|
||||
rarch_fail(1, "init_menu()");
|
||||
}
|
||||
|
||||
if (!(menu_init_list(driver.menu)))
|
||||
if (!(menu_entries_init(driver.menu)))
|
||||
{
|
||||
RARCH_ERR("Cannot initialize menu lists.\n");
|
||||
rarch_fail(1, "init_menu()");
|
||||
|
@ -180,14 +180,11 @@ typedef struct menu_ctx_driver
|
||||
void (*render)(void);
|
||||
void (*frame)(void);
|
||||
void* (*init)(void);
|
||||
bool (*init_lists)(void*);
|
||||
void (*free)(void*);
|
||||
void (*context_reset)(void*);
|
||||
void (*context_destroy)(void*);
|
||||
void (*populate_entries)(void*, const char *, const char *,
|
||||
unsigned);
|
||||
void (*iterate)(void*, unsigned);
|
||||
int (*input_postprocess)(uint64_t, uint64_t);
|
||||
void (*toggle)(bool);
|
||||
void (*navigation_clear)(void *, bool);
|
||||
void (*navigation_decrement)(void *);
|
||||
|
@ -4105,9 +4105,6 @@ static int action_iterate_main(const char *label, unsigned action)
|
||||
|
||||
ret = mouse_post_iterate(cbs, path_offset, label_offset, type_offset, action);
|
||||
|
||||
if (driver.menu_ctx && driver.menu_ctx->iterate)
|
||||
driver.menu_ctx->iterate(driver.menu, action);
|
||||
|
||||
if (driver.video_data && driver.menu_ctx && driver.menu_ctx->render)
|
||||
driver.menu_ctx->render();
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user