mirror of
https://github.com/libretro/RetroArch
synced 2025-02-06 18:40:49 +00:00
ozone: implement bind_init
This commit is contained in:
parent
eee619f64b
commit
28b415f9f2
@ -3767,6 +3767,42 @@ static void ozone_messagebox(void *data, const char *message)
|
||||
ozone->pending_message = strdup(message);
|
||||
}
|
||||
|
||||
static int ozone_deferred_push_content_actions(menu_displaylist_info_t *info)
|
||||
{
|
||||
if (!menu_displaylist_ctl(
|
||||
DISPLAYLIST_HORIZONTAL_CONTENT_ACTIONS, info))
|
||||
return -1;
|
||||
menu_displaylist_process(info);
|
||||
menu_displaylist_info_free(info);
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int ozone_list_bind_init_compare_label(menu_file_list_cbs_t *cbs)
|
||||
{
|
||||
if (cbs && cbs->enum_idx != MSG_UNKNOWN)
|
||||
{
|
||||
switch (cbs->enum_idx)
|
||||
{
|
||||
case MENU_ENUM_LABEL_CONTENT_ACTIONS:
|
||||
cbs->action_deferred_push = ozone_deferred_push_content_actions;
|
||||
break;
|
||||
default:
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int ozone_list_bind_init(menu_file_list_cbs_t *cbs,
|
||||
const char *path, const char *label, unsigned type, size_t idx)
|
||||
{
|
||||
if (ozone_list_bind_init_compare_label(cbs) == 0)
|
||||
return 0;
|
||||
|
||||
return -1;
|
||||
}
|
||||
|
||||
menu_ctx_driver_t menu_ctx_ozone = {
|
||||
NULL, /* set_texture */
|
||||
ozone_messagebox,
|
||||
@ -3797,7 +3833,7 @@ menu_ctx_driver_t menu_ctx_ozone = {
|
||||
ozone_list_get_size,
|
||||
ozone_list_get_entry,
|
||||
NULL, /* list_set_selection */
|
||||
NULL, /* bind_init */
|
||||
ozone_list_bind_init, /* bind_init */
|
||||
NULL, /* load_image */
|
||||
"ozone",
|
||||
ozone_environ_cb,
|
||||
|
@ -5415,7 +5415,7 @@ static void xmb_toggle(void *userdata, bool menu_on)
|
||||
xmb_toggle_horizontal_list(xmb);
|
||||
}
|
||||
|
||||
static int deferred_push_content_actions(menu_displaylist_info_t *info)
|
||||
static int xmb_deferred_push_content_actions(menu_displaylist_info_t *info)
|
||||
{
|
||||
if (!menu_displaylist_ctl(
|
||||
DISPLAYLIST_HORIZONTAL_CONTENT_ACTIONS, info))
|
||||
@ -5432,7 +5432,7 @@ static int xmb_list_bind_init_compare_label(menu_file_list_cbs_t *cbs)
|
||||
switch (cbs->enum_idx)
|
||||
{
|
||||
case MENU_ENUM_LABEL_CONTENT_ACTIONS:
|
||||
cbs->action_deferred_push = deferred_push_content_actions;
|
||||
cbs->action_deferred_push = xmb_deferred_push_content_actions;
|
||||
break;
|
||||
default:
|
||||
return -1;
|
||||
|
Loading…
x
Reference in New Issue
Block a user