Examples: Android+OpenGL: Using ALooper_pollOnce() instead of ALooper_pollAll(). (#8013)

This commit is contained in:
ocornut
2024-11-04 14:24:54 +01:00
parent 71c77c081a
commit f77d22837c
2 changed files with 4 additions and 2 deletions

View File

@@ -68,7 +68,7 @@ void android_main(struct android_app* app)
struct android_poll_source* out_data;
// Poll all events. If the app is not visible, this loop blocks until g_Initialized == true.
while (ALooper_pollAll(g_Initialized ? 0 : -1, nullptr, &out_events, (void**)&out_data) >= 0)
while (ALooper_pollOnce(g_Initialized ? 0 : -1, nullptr, &out_events, (void**)&out_data) >= 0)
{
// Process one event
if (out_data != nullptr)