diff options
-rw-r--r-- | backends/platform/android/gfx.cpp | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/backends/platform/android/gfx.cpp b/backends/platform/android/gfx.cpp index 8a03a19fee..5b03af9698 100644 --- a/backends/platform/android/gfx.cpp +++ b/backends/platform/android/gfx.cpp @@ -286,6 +286,9 @@ void OSystem_Android::initSize(uint width, uint height, void OSystem_Android::clearScreen(FixupType type, byte count) { assert(count > 0); + bool sm = _show_mouse; + _show_mouse = false; + GLCALL(glDisable(GL_SCISSOR_TEST)); for (byte i = 0; i < count; ++i) { @@ -310,6 +313,9 @@ void OSystem_Android::clearScreen(FixupType type, byte count) { if (!_show_overlay) GLCALL(glEnable(GL_SCISSOR_TEST)); + + _show_mouse = sm; + _force_redraw = true; } void OSystem_Android::updateScreenRect() { @@ -592,15 +598,15 @@ void OSystem_Android::showOverlay() { void OSystem_Android::hideOverlay() { ENTER(); - clearScreen(kClear); - _show_overlay = false; - _force_redraw = true; updateEventScale(); warpMouse(_game_texture->width() / 2, _game_texture->height() / 2); + // double buffered, flip twice + clearScreen(kClearUpdate, 2); + GLCALL(glEnable(GL_SCISSOR_TEST)); } |