Issue rendering after Android window rotation

This is a new issue since updated from an older release (SDL 2.0.5 I think) to a fairly recent development version.

SDL_WINDOW_SIZE_CHANGED occurs on a window rotation with the new size. If we render on this frame, the result appears incorrect – perhaps the GL surface view is not actually using this new size yet? The next frame, we render and it looks correct. This does not appear for applications that constantly render and flip the screen buffer, but it occurs for our applications that do not render or swap buffers if the screen is not dirty.

The previous behavior was that we could render immediately after a resize event on Android, and it would look and work correct. Unfortunately, there is no SDL_WINDOW_EXPOSED event following the resize either, so we have added a timer to force rendering for some time after the window is resized.

I’m not sure if you guys were aware of this, and I apologize that I don’t have a better bug report or a fix, pointing at the internals. Thank you so much