Fixed losing ALT key modifiers on Unity
authorSam Lantinga <slouken@libsdl.org>
Mon, 20 May 2013 12:25:16 -0700
changeset 7199 6d4cad3fb837
parent 7198 2928be835dbd
child 7200 54c9f310f7c0
Fixed losing ALT key modifiers on Unity
src/video/x11/SDL_x11events.c
--- a/src/video/x11/SDL_x11events.c	Mon May 20 12:01:31 2013 -0700
+++ b/src/video/x11/SDL_x11events.c	Mon May 20 12:25:16 2013 -0700
@@ -356,7 +356,13 @@
                 /* We want to reset the keyboard here, because we may have
                    missed keyboard messages after our previous FocusOut.
                  */
-                SDL_ResetKeyboard();
+                /* Actually, if we do this we clear the ALT key on Unity
+                   because it briefly takes focus for their dashboard.
+
+                   I think it's better to think the ALT key is held down
+                   when it's not, then always lose the ALT modifier on Unity.
+                 */
+                /*SDL_ResetKeyboard();*/
             }
             data->pending_focus = PENDING_FOCUS_IN;
             data->pending_focus_time = SDL_GetTicks() + PENDING_FOCUS_IN_TIME;