Fix Aurora event processing (fix exit)

This commit is contained in:
PJB3005
2026-03-01 17:29:19 +01:00
parent 247754a11b
commit 3776bd624b
+14 -2
View File
@@ -176,8 +176,18 @@ void main01(void) {
do {
// 1. Update Window Events
const AuroraEvent* event = aurora_update();
if (event && event->type == AURORA_EXIT)
break;
while (true) {
switch (event->type) {
case AURORA_NONE:
goto eventsDone;
case AURORA_EXIT:
goto exit;
}
event++;
}
eventsDone:;
static u32 frame = 0;
frame++;
@@ -202,6 +212,8 @@ void main01(void) {
std::this_thread::sleep_for(std::chrono::milliseconds(16));
} while (true);
exit:;
}
// =========================================================================