Commit 32106283 authored by Emmanuel Gil Peyrot's avatar Emmanuel Gil Peyrot Committed by linkmauve
Browse files

Wayland: Load a bigger cursor theme for HiDPI

parent 5ea6e6cd
......@@ -1067,6 +1067,8 @@ int _glfwPlatformInit(void)
"Wayland: Unable to load default cursor theme");
return GLFW_FALSE;
// If this happens to be NULL, we just fallback to the scale=1 version.
_glfw.wl.cursorThemeHiDPI = wl_cursor_theme_load(NULL, 64, _glfw.wl.shm);
_glfw.wl.cursorSurface =
_glfw.wl.cursorTimerfd = timerfd_create(CLOCK_MONOTONIC, TFD_CLOEXEC);
......@@ -1105,6 +1107,8 @@ void _glfwPlatformTerminate(void)
if (_glfw.wl.cursorTheme)
if (_glfw.wl.cursorThemeHiDPI)
if (_glfw.wl.cursor.handle)
......@@ -240,6 +240,7 @@ typedef struct _GLFWlibraryWayland
int seatVersion;
struct wl_cursor_theme* cursorTheme;
struct wl_cursor_theme* cursorThemeHiDPI;
struct wl_surface* cursorSurface;
int cursorTimerfd;
uint32_t pointerSerial;
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment