瀏覽代碼

Update rcore_desktop.c

pull/3881/head
Ray 9 月之前
父節點
當前提交
28c232d856
共有 1 個檔案被更改,包括 2 行新增4 行删除
  1. +2
    -4
      src/platforms/rcore_desktop.c

+ 2
- 4
src/platforms/rcore_desktop.c 查看文件

@ -972,8 +972,7 @@ void EnableCursor(void)
// Set cursor position in the middle
SetMousePosition(CORE.Window.screen.width/2, CORE.Window.screen.height/2);
if (glfwRawMouseMotionSupported())
glfwSetInputMode(platform.handle, GLFW_RAW_MOUSE_MOTION, GLFW_FALSE);
if (glfwRawMouseMotionSupported()) glfwSetInputMode(platform.handle, GLFW_RAW_MOUSE_MOTION, GLFW_FALSE);
CORE.Input.Mouse.cursorHidden = false;
}
@ -986,8 +985,7 @@ void DisableCursor(void)
// Set cursor position in the middle
SetMousePosition(CORE.Window.screen.width/2, CORE.Window.screen.height/2);
if (glfwRawMouseMotionSupported())
glfwSetInputMode(platform.handle, GLFW_RAW_MOUSE_MOTION, GLFW_TRUE);
if (glfwRawMouseMotionSupported()) glfwSetInputMode(platform.handle, GLFW_RAW_MOUSE_MOTION, GLFW_TRUE);
CORE.Input.Mouse.cursorHidden = true;
}

Loading…
取消
儲存