From 39dc99889f9fd6807d458b4ad578d6a78ee68c46 Mon Sep 17 00:00:00 2001 From: twinaphex Date: Mon, 13 Oct 2014 06:09:29 +0200 Subject: [PATCH] Revert "(GX) Experiment to see if menu triggering can still work through this" This reverts commit b490e2208093cb033cfb551cac655f04fbeedc53. --- input/gx_input.c | 3 ++- input/gx_input_joypad.c | 5 ++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/input/gx_input.c b/input/gx_input.c index 7b07777838..a415fd2d8f 100644 --- a/input/gx_input.c +++ b/input/gx_input.c @@ -94,7 +94,8 @@ static void gx_input_poll(void *data) static bool gx_input_key_pressed(void *data, int key) { - return input_joypad_pressed(&gx_joypad, 0, g_settings.input.binds[0], key); + return (g_extern.lifecycle_state & (1ULL << key)) || + input_joypad_pressed(&gx_joypad, 0, g_settings.input.binds[0], key); } static uint64_t gx_input_get_capabilities(void *data) diff --git a/input/gx_input_joypad.c b/input/gx_input_joypad.c index bb1bae1789..d005d1bb3a 100644 --- a/input/gx_input_joypad.c +++ b/input/gx_input_joypad.c @@ -510,6 +510,9 @@ static void gx_joypad_poll(void) } uint64_t *state_p1 = &pad_state[0]; + uint64_t *lifecycle_state = &g_extern.lifecycle_state; + + *lifecycle_state &= ~((1ULL << RARCH_MENU_TOGGLE)); if (g_menu) { @@ -522,7 +525,7 @@ static void gx_joypad_poll(void) | (1ULL << GX_CLASSIC_HOME) #endif )) - g_extern.lifecycle_state |= (1ULL << RARCH_MENU_TOGGLE); + *lifecycle_state |= (1ULL << RARCH_MENU_TOGGLE); } static bool gx_joypad_query_pad(unsigned pad)