]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - vid_glx.c
added vid_grabkeyboard cvar which defaults to 0, this means that the glx client no...
[xonotic/darkplaces.git] / vid_glx.c
index de1ac666dc29f00015a58f0553f11f7d28e0f4e8..96bf36f26d51d0b2dd2a7e50a55ae22cc4212cb2 100644 (file)
--- a/vid_glx.c
+++ b/vid_glx.c
@@ -287,7 +287,8 @@ static void IN_Activate (qboolean grab)
 #endif
                                XWarpPointer(vidx11_display, None, win, 0, 0, 0, 0, vid.width / 2, vid.height / 2);
 
 #endif
                                XWarpPointer(vidx11_display, None, win, 0, 0, 0, 0, vid.width / 2, vid.height / 2);
 
-                       XGrabKeyboard(vidx11_display, win, False, GrabModeAsync, GrabModeAsync, CurrentTime);
+                       if (vid_grabkeyboard.integer)
+                               XGrabKeyboard(vidx11_display, win, False, GrabModeAsync, GrabModeAsync, CurrentTime);
 
                        mouse_x = mouse_y = 0;
                        cl_ignoremousemove = true;
 
                        mouse_x = mouse_y = 0;
                        cl_ignoremousemove = true;