mirror of
https://github.com/libretro/RetroArch
synced 2025-03-30 07:20:36 +00:00
Communicate better that this is an enum
This commit is contained in:
parent
a2d4d832f6
commit
255ee8766f
@ -686,7 +686,7 @@ static void mui_draw_cursor(mui_handle_t *mui,
|
||||
menu_display_ctl(MENU_DISPLAY_CTL_BLEND_END, NULL);
|
||||
}
|
||||
|
||||
static size_t mui_list_get_size(void *data, menu_list_type_t type)
|
||||
static size_t mui_list_get_size(void *data, enum menu_list_type type)
|
||||
{
|
||||
size_t list_size = 0;
|
||||
(void)data;
|
||||
@ -1345,7 +1345,8 @@ static void mui_preswitch_tabs(mui_handle_t *mui, unsigned action)
|
||||
}
|
||||
}
|
||||
|
||||
static void mui_list_cache(void *data, menu_list_type_t type, unsigned action)
|
||||
static void mui_list_cache(void *data,
|
||||
enum menu_list_type type, unsigned action)
|
||||
{
|
||||
size_t list_size;
|
||||
mui_handle_t *mui = (mui_handle_t*)data;
|
||||
|
@ -267,7 +267,7 @@ static size_t xmb_list_get_selection(void *data)
|
||||
return xmb->categories.selection_ptr;
|
||||
}
|
||||
|
||||
static size_t xmb_list_get_size(void *data, menu_list_type_t type)
|
||||
static size_t xmb_list_get_size(void *data, enum menu_list_type type)
|
||||
{
|
||||
size_t list_size = 0;
|
||||
xmb_handle_t *xmb = (xmb_handle_t*)data;
|
||||
@ -288,8 +288,7 @@ static size_t xmb_list_get_size(void *data, menu_list_type_t type)
|
||||
return list_size;
|
||||
}
|
||||
|
||||
static void *xmb_list_get_entry(void *data,
|
||||
menu_list_type_t type, unsigned i)
|
||||
static void *xmb_list_get_entry(void *data, enum menu_list_type type, unsigned i)
|
||||
{
|
||||
void *ptr = NULL;
|
||||
size_t list_size = 0;
|
||||
@ -2657,7 +2656,7 @@ static void xmb_list_deep_copy(const file_list_t *src, file_list_t *dst)
|
||||
}
|
||||
}
|
||||
|
||||
static void xmb_list_cache(void *data, menu_list_type_t type, unsigned action)
|
||||
static void xmb_list_cache(void *data, enum menu_list_type type, unsigned action)
|
||||
{
|
||||
size_t stack_size, list_size, selection;
|
||||
xmb_handle_t *xmb = (xmb_handle_t*)data;
|
||||
|
@ -331,11 +331,11 @@ typedef struct menu_ctx_driver
|
||||
file_list_t *list, const char *, const char *, size_t);
|
||||
void (*list_free)(file_list_t *list, size_t, size_t);
|
||||
void (*list_clear)(file_list_t *list);
|
||||
void (*list_cache)(void *data, menu_list_type_t, unsigned);
|
||||
void (*list_cache)(void *data, enum menu_list_type, unsigned);
|
||||
int (*list_push)(void *data, void *userdata, menu_displaylist_info_t*, unsigned);
|
||||
size_t(*list_get_selection)(void *data);
|
||||
size_t(*list_get_size)(void *data, menu_list_type_t type);
|
||||
void *(*list_get_entry)(void *data, menu_list_type_t type, unsigned i);
|
||||
size_t(*list_get_size)(void *data, enum menu_list_type type);
|
||||
void *(*list_get_entry)(void *data, enum menu_list_type type, unsigned i);
|
||||
void (*list_set_selection)(void *data, file_list_t *list);
|
||||
int (*bind_init)(menu_file_list_cbs_t *cbs,
|
||||
const char *path, const char *label, unsigned type, size_t idx,
|
||||
@ -362,7 +362,7 @@ typedef struct menu_ctx_list
|
||||
const char *path;
|
||||
const char *label;
|
||||
size_t idx;
|
||||
menu_list_type_t type;
|
||||
enum menu_list_type type;
|
||||
unsigned action;
|
||||
size_t selection;
|
||||
size_t size;
|
||||
|
@ -29,12 +29,35 @@
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
typedef enum
|
||||
enum menu_list_type
|
||||
{
|
||||
MENU_LIST_PLAIN = 0,
|
||||
MENU_LIST_HORIZONTAL,
|
||||
MENU_LIST_TABS
|
||||
} menu_list_type_t;
|
||||
};
|
||||
|
||||
enum menu_entries_ctl_state
|
||||
{
|
||||
MENU_ENTRIES_CTL_NONE = 0,
|
||||
MENU_ENTRIES_CTL_DEINIT,
|
||||
MENU_ENTRIES_CTL_INIT,
|
||||
MENU_ENTRIES_CTL_LIST_GET,
|
||||
MENU_ENTRIES_CTL_LIST_DEINIT,
|
||||
MENU_ENTRIES_CTL_LIST_INIT,
|
||||
MENU_ENTRIES_CTL_SETTINGS_GET,
|
||||
MENU_ENTRIES_CTL_SETTINGS_DEINIT,
|
||||
MENU_ENTRIES_CTL_SETTINGS_INIT,
|
||||
MENU_ENTRIES_CTL_SET_REFRESH,
|
||||
MENU_ENTRIES_CTL_UNSET_REFRESH,
|
||||
MENU_ENTRIES_CTL_NEEDS_REFRESH,
|
||||
/* Sets the starting index of the menu entry list. */
|
||||
MENU_ENTRIES_CTL_SET_START,
|
||||
/* Returns the starting index of the menu entry list. */
|
||||
MENU_ENTRIES_CTL_START_GET,
|
||||
MENU_ENTRIES_CTL_REFRESH,
|
||||
MENU_ENTRIES_CTL_CLEAR,
|
||||
MENU_ENTRIES_CTL_SHOW_BACK
|
||||
};
|
||||
|
||||
typedef struct menu_file_list_cbs
|
||||
{
|
||||
@ -101,28 +124,6 @@ typedef struct menu_file_list_cbs
|
||||
|
||||
} menu_file_list_cbs_t;
|
||||
|
||||
enum menu_entries_ctl_state
|
||||
{
|
||||
MENU_ENTRIES_CTL_NONE = 0,
|
||||
MENU_ENTRIES_CTL_DEINIT,
|
||||
MENU_ENTRIES_CTL_INIT,
|
||||
MENU_ENTRIES_CTL_LIST_GET,
|
||||
MENU_ENTRIES_CTL_LIST_DEINIT,
|
||||
MENU_ENTRIES_CTL_LIST_INIT,
|
||||
MENU_ENTRIES_CTL_SETTINGS_GET,
|
||||
MENU_ENTRIES_CTL_SETTINGS_DEINIT,
|
||||
MENU_ENTRIES_CTL_SETTINGS_INIT,
|
||||
MENU_ENTRIES_CTL_SET_REFRESH,
|
||||
MENU_ENTRIES_CTL_UNSET_REFRESH,
|
||||
MENU_ENTRIES_CTL_NEEDS_REFRESH,
|
||||
/* Sets the starting index of the menu entry list. */
|
||||
MENU_ENTRIES_CTL_SET_START,
|
||||
/* Returns the starting index of the menu entry list. */
|
||||
MENU_ENTRIES_CTL_START_GET,
|
||||
MENU_ENTRIES_CTL_REFRESH,
|
||||
MENU_ENTRIES_CTL_CLEAR,
|
||||
MENU_ENTRIES_CTL_SHOW_BACK
|
||||
};
|
||||
|
||||
typedef struct menu_list menu_list_t;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user