aboutsummaryrefslogtreecommitdiff
path: root/ui/sdl2.c
diff options
context:
space:
mode:
Diffstat (limited to 'ui/sdl2.c')
-rw-r--r--ui/sdl2.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/ui/sdl2.c b/ui/sdl2.c
index 04bbcc78ee..1ae2781624 100644
--- a/ui/sdl2.c
+++ b/ui/sdl2.c
@@ -548,6 +548,16 @@ static void handle_windowevent(SDL_Event *ev)
qemu_system_shutdown_request();
}
break;
+ case SDL_WINDOWEVENT_SHOWN:
+ if (scon->hidden) {
+ SDL_HideWindow(scon->real_window);
+ }
+ break;
+ case SDL_WINDOWEVENT_HIDDEN:
+ if (!scon->hidden) {
+ SDL_ShowWindow(scon->real_window);
+ }
+ break;
}
}