aboutsummaryrefslogtreecommitdiff
path: root/sdl.c
diff options
context:
space:
mode:
Diffstat (limited to 'sdl.c')
-rw-r--r--sdl.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/sdl.c b/sdl.c
index 01d9617a32..ee809daa6e 100644
--- a/sdl.c
+++ b/sdl.c
@@ -301,6 +301,11 @@ static void sdl_refresh(DisplayState *ds)
}
}
break;
+ case SDL_ACTIVEEVENT:
+ if (gui_grab && (ev->active.gain & SDL_ACTIVEEVENTMASK) == 0) {
+ sdl_grab_end();
+ }
+ break;
default:
break;
}