mirror of
https://github.com/libretro/RetroArch
synced 2025-04-02 16:20:39 +00:00
More explicit typecasts to bools
This commit is contained in:
parent
cb0653137f
commit
f51b49f213
@ -1918,7 +1918,7 @@ void win32_check_window(void *data,
|
|||||||
bool video_is_threaded = video_driver_is_threaded();
|
bool video_is_threaded = video_driver_is_threaded();
|
||||||
if (video_is_threaded)
|
if (video_is_threaded)
|
||||||
ui_companion_win32.application->process_events();
|
ui_companion_win32.application->process_events();
|
||||||
*quit = g_win32_flags & WIN32_CMN_FLAG_QUIT;
|
*quit = (g_win32_flags & WIN32_CMN_FLAG_QUIT) ? true : false;
|
||||||
|
|
||||||
if (g_win32_flags & WIN32_CMN_FLAG_RESIZED)
|
if (g_win32_flags & WIN32_CMN_FLAG_RESIZED)
|
||||||
{
|
{
|
||||||
|
@ -1919,7 +1919,7 @@ bool video_driver_supports_rgba(void)
|
|||||||
bool tmp;
|
bool tmp;
|
||||||
video_driver_state_t *video_st = &video_driver_st;
|
video_driver_state_t *video_st = &video_driver_st;
|
||||||
VIDEO_DRIVER_LOCK(video_st);
|
VIDEO_DRIVER_LOCK(video_st);
|
||||||
tmp = video_st->flags & VIDEO_FLAG_USE_RGBA;
|
tmp = (video_st->flags & VIDEO_FLAG_USE_RGBA) ? true : false;
|
||||||
VIDEO_DRIVER_UNLOCK(video_st);
|
VIDEO_DRIVER_UNLOCK(video_st);
|
||||||
return tmp;
|
return tmp;
|
||||||
}
|
}
|
||||||
@ -1945,7 +1945,7 @@ bool video_driver_supports_hdr(void)
|
|||||||
bool tmp;
|
bool tmp;
|
||||||
video_driver_state_t *video_st = &video_driver_st;
|
video_driver_state_t *video_st = &video_driver_st;
|
||||||
VIDEO_DRIVER_LOCK(video_st);
|
VIDEO_DRIVER_LOCK(video_st);
|
||||||
tmp = video_st->flags & VIDEO_FLAG_HDR_SUPPORT;
|
tmp = (video_st->flags & VIDEO_FLAG_HDR_SUPPORT) ? true : false;
|
||||||
VIDEO_DRIVER_UNLOCK(video_st);
|
VIDEO_DRIVER_UNLOCK(video_st);
|
||||||
return tmp;
|
return tmp;
|
||||||
}
|
}
|
||||||
@ -2625,7 +2625,7 @@ void video_driver_build_info(video_frame_info_t *video_info)
|
|||||||
video_info->menu_wallpaper_opacity = settings->floats.menu_wallpaper_opacity;
|
video_info->menu_wallpaper_opacity = settings->floats.menu_wallpaper_opacity;
|
||||||
video_info->menu_framebuffer_opacity = settings->floats.menu_framebuffer_opacity;
|
video_info->menu_framebuffer_opacity = settings->floats.menu_framebuffer_opacity;
|
||||||
video_info->overlay_behind_menu = settings->bools.input_overlay_behind_menu;
|
video_info->overlay_behind_menu = settings->bools.input_overlay_behind_menu;
|
||||||
video_info->libretro_running = runloop_st->current_core.flags & RETRO_CORE_FLAG_GAME_LOADED;
|
video_info->libretro_running = (runloop_st->current_core.flags & RETRO_CORE_FLAG_GAME_LOADED) ? true : false;
|
||||||
#else
|
#else
|
||||||
video_info->menu_is_alive = false;
|
video_info->menu_is_alive = false;
|
||||||
video_info->menu_screensaver_active = false;
|
video_info->menu_screensaver_active = false;
|
||||||
@ -2709,7 +2709,7 @@ const gfx_ctx_driver_t *video_context_driver_init_first(void *data,
|
|||||||
if (i >= 0)
|
if (i >= 0)
|
||||||
{
|
{
|
||||||
const gfx_ctx_driver_t *ctx = video_context_driver_init(
|
const gfx_ctx_driver_t *ctx = video_context_driver_init(
|
||||||
runloop_flags & RUNLOOP_FLAG_CORE_SET_SHARED_CONTEXT,
|
(runloop_flags & RUNLOOP_FLAG_CORE_SET_SHARED_CONTEXT) ? true : false,
|
||||||
settings,
|
settings,
|
||||||
data,
|
data,
|
||||||
gfx_ctx_gl_drivers[i], ident,
|
gfx_ctx_gl_drivers[i], ident,
|
||||||
@ -2725,7 +2725,7 @@ const gfx_ctx_driver_t *video_context_driver_init_first(void *data,
|
|||||||
{
|
{
|
||||||
const gfx_ctx_driver_t *ctx =
|
const gfx_ctx_driver_t *ctx =
|
||||||
video_context_driver_init(
|
video_context_driver_init(
|
||||||
runloop_flags & RUNLOOP_FLAG_CORE_SET_SHARED_CONTEXT,
|
(runloop_flags & RUNLOOP_FLAG_CORE_SET_SHARED_CONTEXT) ? true : false,
|
||||||
settings,
|
settings,
|
||||||
data,
|
data,
|
||||||
gfx_ctx_gl_drivers[i], ident,
|
gfx_ctx_gl_drivers[i], ident,
|
||||||
|
@ -305,7 +305,7 @@ static void dinput_poll(void *data)
|
|||||||
POINT point;
|
POINT point;
|
||||||
DIMOUSESTATE2 mouse_state;
|
DIMOUSESTATE2 mouse_state;
|
||||||
BYTE *rgb_buttons_ptr = &mouse_state.rgbButtons[0];
|
BYTE *rgb_buttons_ptr = &mouse_state.rgbButtons[0];
|
||||||
bool swap_mouse_buttons = g_win32_flags & WIN32_CMN_FLAG_SWAP_MOUSE_BTNS;
|
bool swap_mouse_buttons = (g_win32_flags & WIN32_CMN_FLAG_SWAP_MOUSE_BTNS) ? true : false;
|
||||||
|
|
||||||
point.x = 0;
|
point.x = 0;
|
||||||
point.y = 0;
|
point.y = 0;
|
||||||
@ -412,29 +412,29 @@ static bool dinput_mouse_button_pressed(
|
|||||||
switch (key)
|
switch (key)
|
||||||
{
|
{
|
||||||
case RETRO_DEVICE_ID_MOUSE_LEFT:
|
case RETRO_DEVICE_ID_MOUSE_LEFT:
|
||||||
return (di->flags & DINP_FLAG_MOUSE_L_BTN);
|
return (di->flags & DINP_FLAG_MOUSE_L_BTN) ? true : false;
|
||||||
case RETRO_DEVICE_ID_MOUSE_RIGHT:
|
case RETRO_DEVICE_ID_MOUSE_RIGHT:
|
||||||
return (di->flags & DINP_FLAG_MOUSE_R_BTN);
|
return (di->flags & DINP_FLAG_MOUSE_R_BTN) ? true : false;
|
||||||
case RETRO_DEVICE_ID_MOUSE_MIDDLE:
|
case RETRO_DEVICE_ID_MOUSE_MIDDLE:
|
||||||
return (di->flags & DINP_FLAG_MOUSE_M_BTN);
|
return (di->flags & DINP_FLAG_MOUSE_M_BTN) ? true : false;
|
||||||
case RETRO_DEVICE_ID_MOUSE_BUTTON_4:
|
case RETRO_DEVICE_ID_MOUSE_BUTTON_4:
|
||||||
return (di->flags & DINP_FLAG_MOUSE_B4_BTN);
|
return (di->flags & DINP_FLAG_MOUSE_B4_BTN) ? true : false;
|
||||||
case RETRO_DEVICE_ID_MOUSE_BUTTON_5:
|
case RETRO_DEVICE_ID_MOUSE_BUTTON_5:
|
||||||
return (di->flags & DINP_FLAG_MOUSE_B5_BTN);
|
return (di->flags & DINP_FLAG_MOUSE_B5_BTN) ? true : false;
|
||||||
case RETRO_DEVICE_ID_MOUSE_WHEELUP:
|
case RETRO_DEVICE_ID_MOUSE_WHEELUP:
|
||||||
result = di->flags & DINP_FLAG_MOUSE_WU_BTN;
|
result = (di->flags & DINP_FLAG_MOUSE_WU_BTN) ? true : false;
|
||||||
di->flags &= ~DINP_FLAG_MOUSE_WU_BTN;
|
di->flags &= ~DINP_FLAG_MOUSE_WU_BTN;
|
||||||
break;
|
break;
|
||||||
case RETRO_DEVICE_ID_MOUSE_WHEELDOWN:
|
case RETRO_DEVICE_ID_MOUSE_WHEELDOWN:
|
||||||
result = di->flags & DINP_FLAG_MOUSE_WD_BTN;
|
result = (di->flags & DINP_FLAG_MOUSE_WD_BTN) ? true : false;
|
||||||
di->flags &= ~DINP_FLAG_MOUSE_WD_BTN;
|
di->flags &= ~DINP_FLAG_MOUSE_WD_BTN;
|
||||||
break;
|
break;
|
||||||
case RETRO_DEVICE_ID_MOUSE_HORIZ_WHEELUP:
|
case RETRO_DEVICE_ID_MOUSE_HORIZ_WHEELUP:
|
||||||
result = di->flags & DINP_FLAG_MOUSE_HWU_BTN;
|
result = (di->flags & DINP_FLAG_MOUSE_HWU_BTN) ? true : false;
|
||||||
di->flags &= ~DINP_FLAG_MOUSE_HWU_BTN;
|
di->flags &= ~DINP_FLAG_MOUSE_HWU_BTN;
|
||||||
break;
|
break;
|
||||||
case RETRO_DEVICE_ID_MOUSE_HORIZ_WHEELDOWN:
|
case RETRO_DEVICE_ID_MOUSE_HORIZ_WHEELDOWN:
|
||||||
result = di->flags & DINP_FLAG_MOUSE_HWD_BTN;
|
result = (di->flags & DINP_FLAG_MOUSE_HWD_BTN) ? true : false;
|
||||||
di->flags &= ~DINP_FLAG_MOUSE_HWD_BTN;
|
di->flags &= ~DINP_FLAG_MOUSE_HWD_BTN;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -364,7 +364,7 @@ static void winraw_update_mouse_state(winraw_input_t *wr,
|
|||||||
winraw_mouse_t *mouse, RAWMOUSE *state)
|
winraw_mouse_t *mouse, RAWMOUSE *state)
|
||||||
{
|
{
|
||||||
POINT crs_pos;
|
POINT crs_pos;
|
||||||
bool swap_mouse_buttons = g_win32_flags & WIN32_CMN_FLAG_SWAP_MOUSE_BTNS;
|
bool swap_mouse_buttons = (g_win32_flags & WIN32_CMN_FLAG_SWAP_MOUSE_BTNS) ? true : false;
|
||||||
|
|
||||||
/* Used for fixing coordinates after switching resolutions */
|
/* Used for fixing coordinates after switching resolutions */
|
||||||
GetClientRect((HWND)video_driver_window_get(), &wr->prev_rect);
|
GetClientRect((HWND)video_driver_window_get(), &wr->prev_rect);
|
||||||
|
@ -1219,8 +1219,8 @@ static int16_t input_state_device(
|
|||||||
&& BIT256_GET(input_st->overlay_ptr->overlay_state.buttons, id))
|
&& BIT256_GET(input_st->overlay_ptr->overlay_state.buttons, id))
|
||||||
{
|
{
|
||||||
#ifdef HAVE_MENU
|
#ifdef HAVE_MENU
|
||||||
bool menu_driver_alive = menu_state_get_ptr()->flags &
|
bool menu_driver_alive = (menu_state_get_ptr()->flags &
|
||||||
MENU_ST_FLAG_ALIVE;
|
MENU_ST_FLAG_ALIVE) ? true : false;
|
||||||
#else
|
#else
|
||||||
bool menu_driver_alive = false;
|
bool menu_driver_alive = false;
|
||||||
#endif
|
#endif
|
||||||
@ -1591,7 +1591,7 @@ static int16_t input_state_internal(
|
|||||||
sec_joypad,
|
sec_joypad,
|
||||||
&joypad_info,
|
&joypad_info,
|
||||||
(*input_st->libretro_input_binds),
|
(*input_st->libretro_input_binds),
|
||||||
input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED,
|
(input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED) ? true : false,
|
||||||
mapped_port, device, idx, id);
|
mapped_port, device, idx, id);
|
||||||
|
|
||||||
if ( (device == RETRO_DEVICE_ANALOG)
|
if ( (device == RETRO_DEVICE_ANALOG)
|
||||||
@ -4791,7 +4791,7 @@ static void input_keys_pressed(
|
|||||||
sec_joypad,
|
sec_joypad,
|
||||||
joypad_info,
|
joypad_info,
|
||||||
binds,
|
binds,
|
||||||
input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED,
|
(input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED) ? true : false,
|
||||||
port, RETRO_DEVICE_JOYPAD, 0,
|
port, RETRO_DEVICE_JOYPAD, 0,
|
||||||
RARCH_ENABLE_HOTKEY))
|
RARCH_ENABLE_HOTKEY))
|
||||||
{
|
{
|
||||||
@ -4825,7 +4825,7 @@ static void input_keys_pressed(
|
|||||||
sec_joypad,
|
sec_joypad,
|
||||||
joypad_info,
|
joypad_info,
|
||||||
binds,
|
binds,
|
||||||
input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED,
|
(input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED) ? true : false,
|
||||||
port, RETRO_DEVICE_JOYPAD, 0,
|
port, RETRO_DEVICE_JOYPAD, 0,
|
||||||
RARCH_GAME_FOCUS_TOGGLE))
|
RARCH_GAME_FOCUS_TOGGLE))
|
||||||
input_st->flags &= ~INP_FLAG_BLOCK_HOTKEY;
|
input_st->flags &= ~INP_FLAG_BLOCK_HOTKEY;
|
||||||
@ -4847,7 +4847,7 @@ static void input_keys_pressed(
|
|||||||
sec_joypad,
|
sec_joypad,
|
||||||
joypad_info,
|
joypad_info,
|
||||||
binds,
|
binds,
|
||||||
input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED,
|
(input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED) ? true : false,
|
||||||
port, RETRO_DEVICE_JOYPAD, 0,
|
port, RETRO_DEVICE_JOYPAD, 0,
|
||||||
RETRO_DEVICE_ID_JOYPAD_MASK);
|
RETRO_DEVICE_ID_JOYPAD_MASK);
|
||||||
|
|
||||||
@ -4879,7 +4879,7 @@ static void input_keys_pressed(
|
|||||||
sec_joypad,
|
sec_joypad,
|
||||||
joypad_info,
|
joypad_info,
|
||||||
binds,
|
binds,
|
||||||
input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED,
|
(input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED) ? true : false,
|
||||||
port, RETRO_DEVICE_KEYBOARD, 0,
|
port, RETRO_DEVICE_KEYBOARD, 0,
|
||||||
input_config_binds[port][i].key);
|
input_config_binds[port][i].key);
|
||||||
|
|
||||||
@ -4893,7 +4893,7 @@ static void input_keys_pressed(
|
|||||||
sec_joypad,
|
sec_joypad,
|
||||||
joypad_info,
|
joypad_info,
|
||||||
binds,
|
binds,
|
||||||
input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED,
|
(input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED) ? true : false,
|
||||||
port, RETRO_DEVICE_JOYPAD, 0, i);
|
port, RETRO_DEVICE_JOYPAD, 0, i);
|
||||||
|
|
||||||
if (
|
if (
|
||||||
@ -4947,7 +4947,7 @@ static void input_keys_pressed(
|
|||||||
sec_joypad,
|
sec_joypad,
|
||||||
joypad_info,
|
joypad_info,
|
||||||
binds,
|
binds,
|
||||||
input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED,
|
(input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED) ? true : false,
|
||||||
port, RETRO_DEVICE_KEYBOARD, 0,
|
port, RETRO_DEVICE_KEYBOARD, 0,
|
||||||
input_config_binds[port][i].key))
|
input_config_binds[port][i].key))
|
||||||
{
|
{
|
||||||
@ -4965,7 +4965,7 @@ static void input_keys_pressed(
|
|||||||
sec_joypad,
|
sec_joypad,
|
||||||
joypad_info,
|
joypad_info,
|
||||||
binds,
|
binds,
|
||||||
input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED,
|
(input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED) ? true : false,
|
||||||
port, RETRO_DEVICE_JOYPAD, 0,
|
port, RETRO_DEVICE_JOYPAD, 0,
|
||||||
i))
|
i))
|
||||||
{
|
{
|
||||||
@ -4991,7 +4991,7 @@ static void input_keys_pressed(
|
|||||||
sec_joypad,
|
sec_joypad,
|
||||||
joypad_info,
|
joypad_info,
|
||||||
binds,
|
binds,
|
||||||
input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED,
|
(input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED) ? true : false,
|
||||||
port, RETRO_DEVICE_KEYBOARD, 0,
|
port, RETRO_DEVICE_KEYBOARD, 0,
|
||||||
input_config_binds[port][i].key))
|
input_config_binds[port][i].key))
|
||||||
{
|
{
|
||||||
@ -5010,7 +5010,7 @@ static void input_keys_pressed(
|
|||||||
sec_joypad,
|
sec_joypad,
|
||||||
joypad_info,
|
joypad_info,
|
||||||
binds,
|
binds,
|
||||||
input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED,
|
(input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED) ? true : false,
|
||||||
port, RETRO_DEVICE_JOYPAD, 0,
|
port, RETRO_DEVICE_JOYPAD, 0,
|
||||||
i))
|
i))
|
||||||
{
|
{
|
||||||
@ -5042,7 +5042,7 @@ static void input_keys_pressed(
|
|||||||
sec_joypad,
|
sec_joypad,
|
||||||
joypad_info,
|
joypad_info,
|
||||||
binds,
|
binds,
|
||||||
input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED,
|
(input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED) ? true : false,
|
||||||
port, RETRO_DEVICE_JOYPAD, 0,
|
port, RETRO_DEVICE_JOYPAD, 0,
|
||||||
i);
|
i);
|
||||||
|
|
||||||
@ -5317,8 +5317,8 @@ bool replay_set_serialized_data(void* buf)
|
|||||||
{
|
{
|
||||||
uint8_t *buffer = buf;
|
uint8_t *buffer = buf;
|
||||||
input_driver_state_t *input_st = &input_driver_st;
|
input_driver_state_t *input_st = &input_driver_st;
|
||||||
bool playback = input_st->bsv_movie_state.flags & BSV_FLAG_MOVIE_PLAYBACK;
|
bool playback = (input_st->bsv_movie_state.flags & BSV_FLAG_MOVIE_PLAYBACK) ? true : false;
|
||||||
bool recording = input_st->bsv_movie_state.flags & BSV_FLAG_MOVIE_RECORDING;
|
bool recording = (input_st->bsv_movie_state.flags & BSV_FLAG_MOVIE_RECORDING) ? true : false;
|
||||||
|
|
||||||
/* If there is no current replay, ignore this entirely.
|
/* If there is no current replay, ignore this entirely.
|
||||||
TODO/FIXME: Later, consider loading up the replay
|
TODO/FIXME: Later, consider loading up the replay
|
||||||
@ -5465,7 +5465,7 @@ void input_driver_poll(void)
|
|||||||
sec_joypad,
|
sec_joypad,
|
||||||
&joypad_info[i],
|
&joypad_info[i],
|
||||||
(*input_st->libretro_input_binds),
|
(*input_st->libretro_input_binds),
|
||||||
input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED,
|
(input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED) ? true : false,
|
||||||
(unsigned)i,
|
(unsigned)i,
|
||||||
RETRO_DEVICE_JOYPAD,
|
RETRO_DEVICE_JOYPAD,
|
||||||
0,
|
0,
|
||||||
@ -5473,8 +5473,8 @@ void input_driver_poll(void)
|
|||||||
}
|
}
|
||||||
|
|
||||||
#ifdef HAVE_OVERLAY
|
#ifdef HAVE_OVERLAY
|
||||||
if (input_st->overlay_ptr &&
|
if ( input_st->overlay_ptr
|
||||||
(input_st->overlay_ptr->flags & INPUT_OVERLAY_ALIVE))
|
&& (input_st->overlay_ptr->flags & INPUT_OVERLAY_ALIVE))
|
||||||
{
|
{
|
||||||
unsigned input_analog_dpad_mode = settings->uints.input_analog_dpad_mode[0];
|
unsigned input_analog_dpad_mode = settings->uints.input_analog_dpad_mode[0];
|
||||||
float input_overlay_opacity = (input_st->overlay_ptr->flags & INPUT_OVERLAY_IS_OSK)
|
float input_overlay_opacity = (input_st->overlay_ptr->flags & INPUT_OVERLAY_IS_OSK)
|
||||||
@ -5502,7 +5502,7 @@ void input_driver_poll(void)
|
|||||||
}
|
}
|
||||||
|
|
||||||
input_poll_overlay(
|
input_poll_overlay(
|
||||||
input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED,
|
(input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED) ? true : false,
|
||||||
settings,
|
settings,
|
||||||
input_st->overlay_ptr,
|
input_st->overlay_ptr,
|
||||||
input_st->overlay_visibility,
|
input_st->overlay_visibility,
|
||||||
@ -5568,7 +5568,7 @@ void input_driver_poll(void)
|
|||||||
sec_joypad,
|
sec_joypad,
|
||||||
&joypad_info[i],
|
&joypad_info[i],
|
||||||
(*input_st->libretro_input_binds),
|
(*input_st->libretro_input_binds),
|
||||||
input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED,
|
(input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED) ? true : false,
|
||||||
(unsigned)i, RETRO_DEVICE_JOYPAD,
|
(unsigned)i, RETRO_DEVICE_JOYPAD,
|
||||||
0, RETRO_DEVICE_ID_JOYPAD_MASK);
|
0, RETRO_DEVICE_ID_JOYPAD_MASK);
|
||||||
|
|
||||||
@ -6172,8 +6172,8 @@ void input_driver_collect_system_input(input_driver_state_t *input_st,
|
|||||||
#endif
|
#endif
|
||||||
#ifdef HAVE_MENU
|
#ifdef HAVE_MENU
|
||||||
bool display_kb = menu_input_dialog_get_display_kb();
|
bool display_kb = menu_input_dialog_get_display_kb();
|
||||||
bool menu_is_alive = menu_state_get_ptr()->flags &
|
bool menu_is_alive = (menu_state_get_ptr()->flags &
|
||||||
MENU_ST_FLAG_ALIVE;
|
MENU_ST_FLAG_ALIVE) ? true : false;
|
||||||
bool menu_input_active = menu_is_alive &&
|
bool menu_input_active = menu_is_alive &&
|
||||||
!(settings->bools.menu_unified_controls && !display_kb);
|
!(settings->bools.menu_unified_controls && !display_kb);
|
||||||
#endif
|
#endif
|
||||||
@ -6325,7 +6325,7 @@ void input_driver_collect_system_input(input_driver_state_t *input_st,
|
|||||||
sec_joypad,
|
sec_joypad,
|
||||||
&joypad_info,
|
&joypad_info,
|
||||||
(const retro_keybind_set *)input_config_binds,
|
(const retro_keybind_set *)input_config_binds,
|
||||||
input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED,
|
(input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED) ? true : false,
|
||||||
0,
|
0,
|
||||||
RETRO_DEVICE_KEYBOARD, 0, ids[i][0]))
|
RETRO_DEVICE_KEYBOARD, 0, ids[i][0]))
|
||||||
BIT256_SET_PTR(current_bits, ids[i][1]);
|
BIT256_SET_PTR(current_bits, ids[i][1]);
|
||||||
|
@ -4799,8 +4799,8 @@ static void cb_net_generic(retro_task_t *task,
|
|||||||
finish:
|
finish:
|
||||||
menu_st->flags &= ~MENU_ST_FLAG_ENTRIES_NONBLOCKING_REFRESH;
|
menu_st->flags &= ~MENU_ST_FLAG_ENTRIES_NONBLOCKING_REFRESH;
|
||||||
|
|
||||||
if (!err &&
|
if ( !err
|
||||||
!string_ends_with_size(state->path,
|
&& !string_ends_with_size(state->path,
|
||||||
FILE_PATH_INDEX_DIRS_URL,
|
FILE_PATH_INDEX_DIRS_URL,
|
||||||
strlen(state->path),
|
strlen(state->path),
|
||||||
STRLEN_CONST(FILE_PATH_INDEX_DIRS_URL)
|
STRLEN_CONST(FILE_PATH_INDEX_DIRS_URL)
|
||||||
|
@ -364,7 +364,7 @@ void menu_entry_get(menu_entry_t *entry, size_t stack_idx,
|
|||||||
if (!list)
|
if (!list)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
path_enabled = entry_flags & MENU_ENTRY_FLAG_PATH_ENABLED;
|
path_enabled = (entry_flags & MENU_ENTRY_FLAG_PATH_ENABLED) ? true : false;
|
||||||
|
|
||||||
path = list->list[i].path;
|
path = list->list[i].path;
|
||||||
entry_label = list->list[i].label;
|
entry_label = list->list[i].label;
|
||||||
@ -421,9 +421,9 @@ void menu_entry_get(menu_entry_t *entry, size_t stack_idx,
|
|||||||
path_enabled = true;
|
path_enabled = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((path_enabled || (entry_flags & MENU_ENTRY_FLAG_VALUE_ENABLED)) &&
|
if ((path_enabled || (entry_flags & MENU_ENTRY_FLAG_VALUE_ENABLED))
|
||||||
cbs->action_get_value &&
|
&& cbs->action_get_value
|
||||||
use_representation)
|
&& use_representation)
|
||||||
{
|
{
|
||||||
cbs->action_get_value(list,
|
cbs->action_get_value(list,
|
||||||
&entry->spacing, entry->type,
|
&entry->spacing, entry->type,
|
||||||
@ -4789,7 +4789,7 @@ bool menu_input_key_bind_set_mode(
|
|||||||
settings->floats.input_axis_threshold,
|
settings->floats.input_axis_threshold,
|
||||||
settings->uints.input_joypad_index[binds->port],
|
settings->uints.input_joypad_index[binds->port],
|
||||||
binds, false,
|
binds, false,
|
||||||
input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED);
|
(input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED) ? true : false);
|
||||||
|
|
||||||
current_usec = cpu_features_get_time_usec();
|
current_usec = cpu_features_get_time_usec();
|
||||||
|
|
||||||
@ -4898,7 +4898,7 @@ static bool menu_input_key_bind_iterate(
|
|||||||
settings->floats.input_axis_threshold,
|
settings->floats.input_axis_threshold,
|
||||||
settings->uints.input_joypad_index[new_binds.port],
|
settings->uints.input_joypad_index[new_binds.port],
|
||||||
&new_binds, timed_out,
|
&new_binds, timed_out,
|
||||||
input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED);
|
(input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED) ? true : false);
|
||||||
|
|
||||||
#ifdef ANDROID
|
#ifdef ANDROID
|
||||||
/* Keep resetting bind during the hold period,
|
/* Keep resetting bind during the hold period,
|
||||||
@ -5018,7 +5018,7 @@ bool menu_input_dialog_get_display_kb(void)
|
|||||||
/* swkbd only works on "real" titles */
|
/* swkbd only works on "real" titles */
|
||||||
if ( __nx_applet_type != AppletType_Application
|
if ( __nx_applet_type != AppletType_Application
|
||||||
&& __nx_applet_type != AppletType_SystemApplication)
|
&& __nx_applet_type != AppletType_SystemApplication)
|
||||||
return (menu_st->flags & MENU_ST_FLAG_INP_DLG_KB_DISPLAY);
|
return ((menu_st->flags & MENU_ST_FLAG_INP_DLG_KB_DISPLAY) > 0);
|
||||||
|
|
||||||
if (!(menu_st->flags & MENU_ST_FLAG_INP_DLG_KB_DISPLAY))
|
if (!(menu_st->flags & MENU_ST_FLAG_INP_DLG_KB_DISPLAY))
|
||||||
return false;
|
return false;
|
||||||
@ -5111,7 +5111,7 @@ unsigned menu_event(
|
|||||||
gfx_display_t *p_disp = disp_get_ptr();
|
gfx_display_t *p_disp = disp_get_ptr();
|
||||||
menu_input_pointer_hw_state_t *pointer_hw_state = &menu_st->input_pointer_hw_state;
|
menu_input_pointer_hw_state_t *pointer_hw_state = &menu_st->input_pointer_hw_state;
|
||||||
menu_handle_t *menu = menu_st->driver_data;
|
menu_handle_t *menu = menu_st->driver_data;
|
||||||
bool keyboard_mapping_blocked = input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED;
|
bool keyboard_mapping_blocked = (input_st->flags & INP_FLAG_KB_MAPPING_BLOCKED) ? true : false;
|
||||||
bool menu_mouse_enable = settings->bools.menu_mouse_enable;
|
bool menu_mouse_enable = settings->bools.menu_mouse_enable;
|
||||||
bool menu_pointer_enable = settings->bools.menu_pointer_enable;
|
bool menu_pointer_enable = settings->bools.menu_pointer_enable;
|
||||||
bool swap_ok_cancel_btns = settings->bools.input_menu_swap_ok_cancel_buttons;
|
bool swap_ok_cancel_btns = settings->bools.input_menu_swap_ok_cancel_buttons;
|
||||||
@ -6156,8 +6156,8 @@ void menu_driver_toggle(
|
|||||||
bool pause_libretro = false;
|
bool pause_libretro = false;
|
||||||
runloop_state_t *runloop_st = runloop_state_get_ptr();
|
runloop_state_t *runloop_st = runloop_state_get_ptr();
|
||||||
struct menu_state *menu_st = &menu_driver_state;
|
struct menu_state *menu_st = &menu_driver_state;
|
||||||
bool runloop_shutdown_initiated = runloop_st->flags &
|
bool runloop_shutdown_initiated = (runloop_st->flags &
|
||||||
RUNLOOP_FLAG_SHUTDOWN_INITIATED;
|
RUNLOOP_FLAG_SHUTDOWN_INITIATED) ? true : false;
|
||||||
#ifdef HAVE_OVERLAY
|
#ifdef HAVE_OVERLAY
|
||||||
bool input_overlay_hide_in_menu = false;
|
bool input_overlay_hide_in_menu = false;
|
||||||
bool input_overlay_enable = false;
|
bool input_overlay_enable = false;
|
||||||
@ -6310,7 +6310,7 @@ void retroarch_menu_running(void)
|
|||||||
menu,
|
menu,
|
||||||
menu_input,
|
menu_input,
|
||||||
settings,
|
settings,
|
||||||
menu_st->flags & MENU_ST_FLAG_ALIVE,
|
(menu_st->flags & MENU_ST_FLAG_ALIVE) ? true : false,
|
||||||
#ifdef HAVE_OVERLAY
|
#ifdef HAVE_OVERLAY
|
||||||
input_st->overlay_ptr
|
input_st->overlay_ptr
|
||||||
&& (input_st->overlay_ptr->flags & INPUT_OVERLAY_ALIVE),
|
&& (input_st->overlay_ptr->flags & INPUT_OVERLAY_ALIVE),
|
||||||
@ -7647,10 +7647,10 @@ int generic_menu_entry_action(
|
|||||||
if ( (menu_st->flags & MENU_ST_FLAG_PENDING_CLOSE_CONTENT)
|
if ( (menu_st->flags & MENU_ST_FLAG_PENDING_CLOSE_CONTENT)
|
||||||
|| (menu_st->flags & MENU_ST_FLAG_PENDING_ENV_SHUTDOWN_FLUSH))
|
|| (menu_st->flags & MENU_ST_FLAG_PENDING_ENV_SHUTDOWN_FLUSH))
|
||||||
{
|
{
|
||||||
const char *content_path = (menu_st->flags &
|
const char *content_path = (menu_st->flags
|
||||||
MENU_ST_FLAG_PENDING_ENV_SHUTDOWN_FLUSH) ?
|
& MENU_ST_FLAG_PENDING_ENV_SHUTDOWN_FLUSH)
|
||||||
menu_st->pending_env_shutdown_content_path :
|
? menu_st->pending_env_shutdown_content_path
|
||||||
path_get(RARCH_PATH_CONTENT);
|
: path_get(RARCH_PATH_CONTENT);
|
||||||
const char *deferred_path = menu ? menu->deferred_path : NULL;
|
const char *deferred_path = menu ? menu->deferred_path : NULL;
|
||||||
const char *flush_target = msg_hash_to_str(MENU_ENUM_LABEL_MAIN_MENU);
|
const char *flush_target = msg_hash_to_str(MENU_ENUM_LABEL_MAIN_MENU);
|
||||||
size_t stack_offset = 1;
|
size_t stack_offset = 1;
|
||||||
|
@ -7859,8 +7859,8 @@ static enum event_command write_handler_get_cmd(rarch_setting_t *setting)
|
|||||||
if (*setting->value.target.boolean)
|
if (*setting->value.target.boolean)
|
||||||
*setting->value.target.boolean = false;
|
*setting->value.target.boolean = false;
|
||||||
|
|
||||||
if ( (flags & SD_FLAG_CMD_TRIGGER_EVENT_TRIGGERED) ||
|
if ( (flags & SD_FLAG_CMD_TRIGGER_EVENT_TRIGGERED)
|
||||||
(flags & SD_FLAG_CMD_APPLY_AUTO))
|
|| (flags & SD_FLAG_CMD_APPLY_AUTO))
|
||||||
return setting->cmd_trigger_idx;
|
return setting->cmd_trigger_idx;
|
||||||
}
|
}
|
||||||
return CMD_EVENT_NONE;
|
return CMD_EVENT_NONE;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user