ref(input): move mouse.zig and key.zig into public input.zig namespace
All checks were successful
Zig Project Action / Lint, Spell-check and test zig project (push) Successful in 1m41s

This commit is contained in:
2025-02-18 18:24:09 +01:00
parent e2f9408850
commit f66a870223
8 changed files with 121 additions and 107 deletions

View File

@@ -119,9 +119,9 @@ pub fn main() !void {
.quit => break,
.resize => |size| try renderer.resize(size),
.key => |key| {
if (key.matches(.{ .cp = 'q' })) app.quit();
if (key.eql(.{ .cp = 'q' })) app.quit();
if (key.matches(.{ .cp = 'n', .mod = .{ .ctrl = true } })) {
if (key.eql(.{ .cp = 'n', .mod = .{ .ctrl = true } })) {
try app.interrupt();
defer app.start() catch @panic("could not start app event loop");
var child = std.process.Child.init(&.{"hx"}, allocator);