mirror of
https://github.com/CTCaer/RetroArch.git
synced 2024-12-22 10:49:02 +00:00
Turn menu_animation_ctx_tag into typedef
This commit is contained in:
parent
4e66ec28cb
commit
22139dc4a0
@ -1087,7 +1087,7 @@ static void xmb_selection_pointer_changed(
|
||||
{
|
||||
menu_entry_t e;
|
||||
unsigned i, end, height;
|
||||
menu_animation_ctx_tag_t tag;
|
||||
menu_animation_ctx_tag tag;
|
||||
size_t num = 0;
|
||||
int threshold = 0;
|
||||
menu_list_t *menu_list = NULL;
|
||||
@ -1118,7 +1118,7 @@ static void xmb_selection_pointer_changed(
|
||||
|
||||
video_driver_get_size(NULL, &height);
|
||||
|
||||
tag.id = (uintptr_t)selection_buf;
|
||||
tag = (uintptr_t)selection_buf;
|
||||
|
||||
menu_animation_ctl(MENU_ANIMATION_CTL_KILL_BY_TAG, &tag);
|
||||
menu_entries_ctl(MENU_ENTRIES_CTL_SET_START, &num);
|
||||
@ -1190,7 +1190,7 @@ static void xmb_selection_pointer_changed(
|
||||
entry.target_value = ia;
|
||||
entry.subject = &node->alpha;
|
||||
entry.easing_enum = EASING_OUT_QUAD;
|
||||
entry.tag = tag.id;
|
||||
entry.tag = tag;
|
||||
entry.cb = NULL;
|
||||
|
||||
if (entry.subject)
|
||||
@ -3735,11 +3735,9 @@ static void xmb_list_insert(void *userdata,
|
||||
static void xmb_list_clear(file_list_t *list)
|
||||
{
|
||||
size_t i;
|
||||
menu_animation_ctx_tag_t tag;
|
||||
size_t size = list->size;
|
||||
size_t size = list->size;
|
||||
menu_animation_ctx_tag tag = (uintptr_t)list;
|
||||
|
||||
tag.id = (uintptr_t)list;
|
||||
|
||||
menu_animation_ctl(MENU_ANIMATION_CTL_KILL_BY_TAG, &tag);
|
||||
|
||||
for (i = 0; i < size; ++i)
|
||||
@ -3757,10 +3755,8 @@ static void xmb_list_clear(file_list_t *list)
|
||||
static void xmb_list_deep_copy(const file_list_t *src, file_list_t *dst)
|
||||
{
|
||||
size_t i;
|
||||
menu_animation_ctx_tag_t tag;
|
||||
size_t size = dst->size;
|
||||
|
||||
tag.id = (uintptr_t)dst;
|
||||
menu_animation_ctx_tag tag = (uintptr_t)dst;
|
||||
size_t size = dst->size;
|
||||
|
||||
menu_animation_ctl(MENU_ANIMATION_CTL_KILL_BY_TAG, &tag);
|
||||
|
||||
|
@ -648,14 +648,14 @@ bool menu_animation_ctl(enum menu_animation_ctl_state state, void *data)
|
||||
case MENU_ANIMATION_CTL_KILL_BY_TAG:
|
||||
{
|
||||
unsigned i;
|
||||
menu_animation_ctx_tag_t *tag = (menu_animation_ctx_tag_t*)data;
|
||||
menu_animation_ctx_tag *tag = (menu_animation_ctx_tag*)data;
|
||||
|
||||
if (!tag || tag->id == (uintptr_t)-1)
|
||||
if (!tag || *tag == (uintptr_t)-1)
|
||||
return false;
|
||||
|
||||
for (i = 0; i < anim.size; ++i)
|
||||
{
|
||||
if (anim.list[i].tag != tag->id)
|
||||
if (anim.list[i].tag != *tag)
|
||||
continue;
|
||||
|
||||
anim.list[i].alive = false;
|
||||
|
@ -91,10 +91,7 @@ typedef struct menu_animation_ctx_delta
|
||||
float ideal;
|
||||
} menu_animation_ctx_delta_t;
|
||||
|
||||
typedef struct menu_animation_ctx_tag
|
||||
{
|
||||
uintptr_t id;
|
||||
} menu_animation_ctx_tag_t;
|
||||
typedef uintptr_t menu_animation_ctx_tag;
|
||||
|
||||
typedef struct menu_animation_ctx_subject
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user