commit f2bb12ebd112fb954fb57a3b12d097a405f02f00 parent a788ce554dcad8abcf438b6aa93b4613f001ae63 Author: Michael Savage <mikejsavage@gmail.com> Date: Sat Sep 2 19:11:56 +0300 Don't centre the mouse when opening the launcher Diffstat:
gl.cc | | | 6 | ++++-- |
diff --git a/gl.cc b/gl.cc @@ -178,8 +178,10 @@ GLFWwindow * gl_init( WindowType window_type ) { window_size = v2u32( checked_cast< u32 >( width ), checked_cast< u32 >( height ) ); - glfwSetCursorPos( window, width / 2, height / 2 ); - glfwSetWindowFocusCallback( window, glfw_focus_callback ); + if( window_type == WINDOW_GAME ) { + glfwSetCursorPos( window, width / 2, height / 2 ); + glfwSetWindowFocusCallback( window, glfw_focus_callback ); + } glfwMakeContextCurrent( window );