mirror of
https://github.com/libretro/RetroArch
synced 2025-04-16 08:43:10 +00:00
(Android) Set g_runloop.is_idle to conserve on CPU usage while
idle
This commit is contained in:
parent
f4c57d11d9
commit
f87f3596ef
@ -96,6 +96,7 @@ void engine_handle_cmd(void *data)
|
|||||||
{
|
{
|
||||||
RARCH_LOG("Pausing RetroArch.\n");
|
RARCH_LOG("Pausing RetroArch.\n");
|
||||||
g_runloop.is_paused = true;
|
g_runloop.is_paused = true;
|
||||||
|
g_runloop.is_idle = true;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
@ -125,6 +126,7 @@ void engine_handle_cmd(void *data)
|
|||||||
|
|
||||||
case APP_CMD_GAINED_FOCUS:
|
case APP_CMD_GAINED_FOCUS:
|
||||||
g_runloop.is_paused = false;
|
g_runloop.is_paused = false;
|
||||||
|
g_runloop.is_idle = false;
|
||||||
|
|
||||||
if ((android_app->sensor_state_mask
|
if ((android_app->sensor_state_mask
|
||||||
& (1ULL << RETRO_SENSOR_ACCELEROMETER_ENABLE))
|
& (1ULL << RETRO_SENSOR_ACCELEROMETER_ENABLE))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user