diff options
Diffstat (limited to 'src/gui')
| -rw-r--r-- | src/gui/gui.zig | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/gui/gui.zig b/src/gui/gui.zig index ef2422c5..7d2a8cf1 100644 --- a/src/gui/gui.zig +++ b/src/gui/gui.zig @@ -1012,9 +1012,10 @@ fn runNative(init: std.process.Init, opts_in: pardes.Options) !void { if (c.SDL_CreateCursor(&p9_arrow_set, &p9_arrow_mask, 16, 16, 1, 1)) |cur| { _ = c.SDL_SetCursor(cur); } else log.err("SDL_CreateCursor: {s}", .{c.SDL_GetError()}); - // fullscreen deck use: keep the pointer inside the window. Absolute - // coords stay (no relative mode — clicks need positions). - if (!test_mode) _ = c.SDL_SetWindowMouseGrab(window, true); + // Keep the window's mouse ungrabbed: desktop users must be able to move + // the pointer out normally. The deck's virtual pointer is clamped and + // warped explicitly only when its controls move it (see dispatch and + // pollGamepad), so it does not need window-wide confinement. const device = c.SDL_CreateGPUDevice(c.SDL_GPU_SHADERFORMAT_SPIRV, true, null) orelse { log.err("SDL_CreateGPUDevice: {s}", .{c.SDL_GetError()}); return error.SdlInit; |
