I built testgesture.c for Android and installed it successfully:
./androidbuild.sh org.libsdl.testgesture …/test/testgesture.c
ant debug install
The testgesture application works as intended, but when I put my
devices in sleep mode and awake them after, the application can no
longer update the screen (whatever has been on the screen before is
still there). The rest of the application however still works (events
come in and get proceeded). Changing the device from landscape to
portrait mode fixes the problem.
I noticed that the return value of SDL_UpdateWindowSurface() in
DrawScreen() is -1 after a resume and the output of SDL_GetError() is
Window surface is invalid, please call SDL_GetWindowSurface() to get
a new surface
Calling SDL_GetWindowSurface() indeed allows the screen to "come back"
to life. However, I do not think that this is a good fix for this problem.
1: Nexus 5/Android 4.4.2, Archos 80 G9/Android 4.0.4, HTC