Added test debug logs for additional event types
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62
diff --git a/src/test/SDL_test_common.c b/src/test/SDL_test_common.c
index ca0aa31..184a097 100644
--- a/src/test/SDL_test_common.c
+++ b/src/test/SDL_test_common.c
@@ -1077,7 +1077,7 @@ SDLTest_PrintEvent(SDL_Event * event)
SDL_Log("SDL EVENT: Window %d hit test", event->window.windowID);
break;
default:
- SDL_Log("SDL EVENT: Window %d got unknown event %d",
+ SDL_Log("SDL EVENT: Window %d got unknown event 0x%4.4x",
event->window.windowID, event->window.event);
break;
}
@@ -1206,6 +1206,13 @@ SDLTest_PrintEvent(SDL_Event * event)
SDL_Log("SDL EVENT: Clipboard updated");
break;
+ case SDL_FINGERMOTION:
+ SDL_Log("SDL EVENT: Finger: motion touch=%ld, finger=%ld, x=%f, y=%f, dx=%f, dy=%f, pressure=%f",
+ (long) event->tfinger.touchId,
+ (long) event->tfinger.fingerId,
+ event->tfinger.x, event->tfinger.y,
+ event->tfinger.dx, event->tfinger.dy, event->tfinger.pressure);
+ break;
case SDL_FINGERDOWN:
case SDL_FINGERUP:
SDL_Log("SDL EVENT: Finger: %s touch=%ld, finger=%ld, x=%f, y=%f, dx=%f, dy=%f, pressure=%f",
@@ -1232,6 +1239,25 @@ SDLTest_PrintEvent(SDL_Event * event)
SDL_Log("SDL EVENT: render targets reset");
break;
+ case SDL_APP_TERMINATING:
+ SDL_Log("SDL EVENT: App terminating");
+ break;
+ case SDL_APP_LOWMEMORY:
+ SDL_Log("SDL EVENT: App running low on memory");
+ break;
+ case SDL_APP_WILLENTERBACKGROUND:
+ SDL_Log("SDL EVENT: App will enter the background");
+ break;
+ case SDL_APP_DIDENTERBACKGROUND:
+ SDL_Log("SDL EVENT: App entered the background");
+ break;
+ case SDL_APP_WILLENTERFOREGROUND:
+ SDL_Log("SDL EVENT: App will enter the foreground");
+ break;
+ case SDL_APP_DIDENTERFOREGROUND:
+ SDL_Log("SDL EVENT: App entered the foreground");
+ break;
+
case SDL_QUIT:
SDL_Log("SDL EVENT: Quit requested");
break;
@@ -1239,7 +1265,7 @@ SDLTest_PrintEvent(SDL_Event * event)
SDL_Log("SDL EVENT: User event %d", event->user.code);
break;
default:
- SDL_Log("Unknown event %04x", event->type);
+ SDL_Log("Unknown event 0x%4.4x", event->type);
break;
}
}