mirror of
https://github.com/libretro/RetroArch
synced 2025-03-29 22:20:21 +00:00
Reimplement fullscreen toggle
This commit is contained in:
parent
50f3999e9b
commit
56a26e9014
12
runloop.c
12
runloop.c
@ -973,7 +973,6 @@ int rarch_main_iterate(unsigned *sleep_ms)
|
||||
static retro_time_t frame_limit_last_time = 0.0;
|
||||
static retro_input_t last_input = 0;
|
||||
bool menu_toggled = false;
|
||||
bool fullscreen_toggled = false;
|
||||
driver_t *driver = driver_get_ptr();
|
||||
settings_t *settings = config_get_ptr();
|
||||
global_t *global = global_get_ptr();
|
||||
@ -1045,13 +1044,16 @@ int rarch_main_iterate(unsigned *sleep_ms)
|
||||
if (cmd.overlay_next_pressed)
|
||||
event_command(EVENT_CMD_OVERLAY_NEXT);
|
||||
|
||||
fullscreen_toggled = !runloop_ctl(RUNLOOP_CTL_IS_PAUSED, NULL);
|
||||
if (cmd.fullscreen_toggle)
|
||||
{
|
||||
bool fullscreen_toggled = !runloop_ctl(RUNLOOP_CTL_IS_PAUSED, NULL);
|
||||
#ifdef HAVE_MENU
|
||||
fullscreen_toggled = fullscreen_toggled || menu_driver_alive();
|
||||
fullscreen_toggled = fullscreen_toggled || menu_driver_alive();
|
||||
#endif
|
||||
|
||||
if (fullscreen_toggled && cmd.fullscreen_toggle)
|
||||
event_command(EVENT_CMD_FULLSCREEN_TOGGLE);
|
||||
if (fullscreen_toggled)
|
||||
event_command(EVENT_CMD_FULLSCREEN_TOGGLE);
|
||||
}
|
||||
|
||||
if (cmd.grab_mouse_pressed)
|
||||
event_command(EVENT_CMD_GRAB_MOUSE_TOGGLE);
|
||||
|
Loading…
x
Reference in New Issue
Block a user