code: switch to custom wlroots/libwayland bindings

This is a big step up over @cImport() for ergonomics and type safety.
Nearly all void pointer casts have been eliminated!
This commit is contained in:
Isaac Freund
2020-11-04 00:23:21 +01:00
parent 0c5e5a7b4a
commit 20d804cdb5
42 changed files with 1457 additions and 1874 deletions
+6 -5
View File
@@ -18,20 +18,21 @@
const Self = @This();
const std = @import("std");
const wlr = @import("wlroots");
const xkb = @import("xkbcommon");
const c = @import("c.zig");
const util = @import("util.zig");
keysym: c.xkb_keysym_t,
modifiers: u32,
keysym: xkb.Keysym,
modifiers: wlr.Keyboard.ModifierMask,
command_args: []const []const u8,
/// When set to true the mapping will be executed on key release rather than on press
release: bool,
pub fn init(
keysym: c.xkb_keysym_t,
modifiers: u32,
keysym: xkb.Keysym,
modifiers: wlr.Keyboard.ModifierMask,
release: bool,
command_args: []const []const u8,
) !Self {