]> git.jsancho.org Git - lugaru.git/commitdiff
Fixed nomousegrab option
authorCôme Chilliet <come@chilliet.eu>
Sat, 19 Nov 2016 15:43:22 +0000 (23:43 +0800)
committerCôme Chilliet <come@chilliet.eu>
Sat, 19 Nov 2016 16:06:06 +0000 (00:06 +0800)
Fixes #5

Source/OpenGL_Windows.cpp

index d74b557c4aeb66f87a6f046389e9812d2792dca6..433b8d134e55d0b25236cafa21889712b92895e6 100644 (file)
@@ -410,9 +410,8 @@ Boolean SetUp ()
         SDL_GL_SetSwapInterval(1);
 
     SDL_ShowCursor(0);
-    SDL_SetWindowGrab(sdlwindow, SDL_TRUE);
-    SDL_SetRelativeMouseMode(SDL_TRUE);
-
+    if (!cmdline("nomousegrab"))
+        SDL_SetRelativeMouseMode(SDL_TRUE);
 
     initGL();