Fixed an instance of eager cursor loading.
Also fixed a minor formatting issue.
This commit is contained in:
parent
7c3c87abf6
commit
199ee20adb
13
glfw/wl_window.c
vendored
13
glfw/wl_window.c
vendored
@ -1474,8 +1474,6 @@ static bool isPointerLocked(_GLFWwindow* window)
|
||||
|
||||
void _glfwPlatformSetCursor(_GLFWwindow* window, _GLFWcursor* cursor)
|
||||
{
|
||||
struct wl_cursor* defaultCursor;
|
||||
|
||||
if (!_glfw.wl.pointer)
|
||||
return;
|
||||
|
||||
@ -1496,15 +1494,8 @@ void _glfwPlatformSetCursor(_GLFWwindow* window, _GLFWcursor* cursor)
|
||||
setCursorImage(window, &cursor->wl);
|
||||
else
|
||||
{
|
||||
defaultCursor = _glfwLoadCursor(GLFW_ARROW_CURSOR, window->wl.cursorTheme);
|
||||
if (!defaultCursor) return;
|
||||
_GLFWcursorWayland cursorWayland = {
|
||||
defaultCursor,
|
||||
NULL,
|
||||
0, 0,
|
||||
0, 0,
|
||||
0
|
||||
};
|
||||
_GLFWcursorWayland cursorWayland = {0};
|
||||
cursorWayland.shape = GLFW_ARROW_CURSOR;
|
||||
setCursorImage(window, &cursorWayland);
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user