mirror of
https://github.com/CTCaer/RetroArch.git
synced 2024-12-22 10:49:02 +00:00
It should be possible to move the definiton of this struct to
driver.h now - now that all the dependencies are gone
This commit is contained in:
parent
d63a23dd06
commit
9b545db864
@ -762,8 +762,13 @@ bool menu_save_new_config(void)
|
||||
return ret;
|
||||
}
|
||||
|
||||
void menu_poll_bind_state(struct rgui_bind_state *state)
|
||||
void menu_poll_bind_state(void *data)
|
||||
{
|
||||
struct rgui_bind_state *state = (struct rgui_bind_state*)data;
|
||||
|
||||
if (!state)
|
||||
return;
|
||||
|
||||
unsigned i, b, a, h;
|
||||
memset(state->state, 0, sizeof(state->state));
|
||||
state->skip = input_input_state_func(NULL, 0, RETRO_DEVICE_KEYBOARD, 0, RETROK_RETURN);
|
||||
@ -795,10 +800,15 @@ void menu_poll_bind_state(struct rgui_bind_state *state)
|
||||
}
|
||||
}
|
||||
|
||||
void menu_poll_bind_get_rested_axes(struct rgui_bind_state *state)
|
||||
void menu_poll_bind_get_rested_axes(void *data)
|
||||
{
|
||||
unsigned i, a;
|
||||
const rarch_joypad_driver_t *joypad = NULL;
|
||||
struct rgui_bind_state *state = (struct rgui_bind_state*)data;
|
||||
|
||||
if (!state)
|
||||
return;
|
||||
|
||||
if (driver.input && driver.input_data && driver.input->get_joypad_driver)
|
||||
joypad = driver.input->get_joypad_driver(driver.input_data);
|
||||
|
||||
@ -875,9 +885,16 @@ static bool menu_poll_find_trigger_pad(struct rgui_bind_state *state, struct rgu
|
||||
return false;
|
||||
}
|
||||
|
||||
bool menu_poll_find_trigger(struct rgui_bind_state *state, struct rgui_bind_state *new_state)
|
||||
bool menu_poll_find_trigger(void *data1, void *data2)
|
||||
{
|
||||
unsigned i;
|
||||
struct rgui_bind_state *state, *new_state;
|
||||
state = (struct rgui_bind_state*)data1;
|
||||
new_state = (struct rgui_bind_state*)data2;
|
||||
|
||||
if (!state || !new_state)
|
||||
return false;
|
||||
|
||||
for (i = 0; i < MAX_PLAYERS; i++)
|
||||
{
|
||||
if (menu_poll_find_trigger_pad(state, new_state, i))
|
||||
|
@ -94,6 +94,7 @@ typedef enum
|
||||
RGUI_ACTION_NOOP
|
||||
} rgui_action_t;
|
||||
|
||||
|
||||
struct rgui_bind_state_port
|
||||
{
|
||||
bool buttons[RGUI_MAX_BUTTONS];
|
||||
@ -121,11 +122,6 @@ struct rgui_bind_state
|
||||
bool skip;
|
||||
};
|
||||
|
||||
void menu_poll_bind_get_rested_axes(struct rgui_bind_state *state);
|
||||
void menu_poll_bind_state(struct rgui_bind_state *state);
|
||||
bool menu_poll_find_trigger(struct rgui_bind_state *state, struct rgui_bind_state *new_state);
|
||||
bool menu_custom_bind_keyboard_cb(void *data, unsigned code);
|
||||
|
||||
typedef struct
|
||||
{
|
||||
uint64_t old_input_state;
|
||||
@ -170,10 +166,8 @@ typedef struct
|
||||
struct retro_system_info info;
|
||||
bool load_no_rom;
|
||||
|
||||
#ifdef HAVE_SHADER_MANAGER
|
||||
void *shader;
|
||||
void *parameter_shader; // Points to either shader or graphics driver current shader.
|
||||
#endif
|
||||
unsigned current_pad;
|
||||
|
||||
void *history;
|
||||
@ -194,6 +188,11 @@ typedef struct
|
||||
retro_time_t sleep_msec;
|
||||
} rgui_handle_t;
|
||||
|
||||
void menu_poll_bind_get_rested_axes(void *data);
|
||||
void menu_poll_bind_state(void *data);
|
||||
bool menu_poll_find_trigger(void *data1, void *data2);
|
||||
bool menu_custom_bind_keyboard_cb(void *data, unsigned code);
|
||||
|
||||
void *menu_init(const void *data);
|
||||
bool menu_iterate(void);
|
||||
void menu_free(void *data);
|
||||
|
Loading…
Reference in New Issue
Block a user