Skip to content

Commit 0ec182c

Browse files
joshua-holmesemidoots
authored andcommitted
linux: get build working with new system
1 parent 1fe47b2 commit 0ec182c

File tree

3 files changed

+14
-0
lines changed

3 files changed

+14
-0
lines changed

src/core/Linux.zig

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,11 +25,17 @@ const BackendEnum = enum {
2525
x11,
2626
wayland,
2727
};
28+
2829
const Backend = union(BackendEnum) {
2930
x11: X11,
3031
wayland: Wayland,
3132
};
3233

34+
pub const Native = union(BackendEnum) {
35+
x11: X11.Native,
36+
wayland: Wayland.Native,
37+
};
38+
3339
pub const Linux = @This();
3440

3541
allocator: std.mem.Allocator,
@@ -52,6 +58,10 @@ backend: Backend,
5258
const MISSING_FEATURES_X11 = [_][]const u8{ "Resizing window", "Changing display mode", "VSync", "Setting window border/cursor" };
5359
const MISSING_FEATURES_WAYLAND = [_][]const u8{ "Changing display mode", "VSync", "Setting window border/cursor" };
5460

61+
pub fn tick(core: *Core) !void {
62+
_ = core;
63+
}
64+
5565
pub fn init(
5666
linux: *Linux,
5767
core: *Core,

src/core/linux/Wayland.zig

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,8 @@ libxkbcommon: LibXkbCommon,
7070
modifiers: Core.KeyMods,
7171
modifier_indices: KeyModInd,
7272

73+
pub const Native = struct {};
74+
7375
pub fn init(
7476
linux: *Linux,
7577
core: *Core,

src/core/linux/X11.zig

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,8 @@ cursors: [@typeInfo(CursorShape).@"enum".fields.len]?c.Cursor,
6161
// Mutable state fields; read/write by any thread
6262
surface_descriptor: *gpu.Surface.DescriptorFromXlibWindow,
6363

64+
pub const Native = struct {};
65+
6466
pub fn init(
6567
linux: *Linux,
6668
core: *Core,

0 commit comments

Comments
 (0)