mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-06-22 22:11:55 +00:00
Fixed bug #14233 - Android fix Android_WaitActiveAndLockActivity() to make sure Android_Paused state is refreshed
(cherry picked from commit e4c60c05bf)
This commit is contained in:
parent
5a9050aea3
commit
92570af7d3
1 changed files with 6 additions and 0 deletions
|
|
@ -248,6 +248,12 @@ void Android_PumpEvents(Sint64 timeoutNS)
|
|||
|
||||
bool Android_WaitActiveAndLockActivity(void)
|
||||
{
|
||||
/* Make sure we have pumped all events so that Android_Paused state is correct */
|
||||
SDL_AndroidLifecycleEvent event;
|
||||
while (!Android_Destroyed && Android_WaitLifecycleEvent(&event, 0)) {
|
||||
Android_HandleLifecycleEvent(event);
|
||||
}
|
||||
|
||||
while (Android_Paused && !Android_Destroyed) {
|
||||
Android_PumpEvents(-1);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue