diff options
| author | Nathan Reiner <nathan@nathanreiner.xyz> | 2025-08-30 15:49:18 +0200 |
|---|---|---|
| committer | Nathan Reiner <nathan@nathanreiner.xyz> | 2025-08-30 15:49:18 +0200 |
| commit | a46436e58beaaa322c082af5e886f96fd31d7a08 (patch) | |
| tree | 05a05b149c2f18cb0562aef94fe41bd5aaad9fbc /src/wl/callback.zig | |
| parent | 4feb8c7dab2b0a3492b8248ee12c3f0a475106f1 (diff) | |
Diffstat (limited to 'src/wl/callback.zig')
| -rw-r--r-- | src/wl/callback.zig | 17 |
1 files changed, 2 insertions, 15 deletions
diff --git a/src/wl/callback.zig b/src/wl/callback.zig index ad2d192..dc9028d 100644 --- a/src/wl/callback.zig +++ b/src/wl/callback.zig @@ -9,21 +9,8 @@ const Self = @This(); pub const Events = wayland.EventSet(Self, .{done}); is_done: *bool, -handle: wayland.Object.Ref, - -pub fn init( - self: *Self, - ctx: wayland.Context, - is_done: *bool, -) !void { - self.is_done = is_done; - self.handle = try ctx.display.registry.add_object( - ctx.allocator, - wayland.Object.from_self(self), - ); - try ctx.display.request(ctx.display, .{ .sync = .{self.handle} }); - -} +handle: wayland.Object.Ref = .null, +init: wayland.Object.interface.Init(Self) = .{}, pub fn deinit(self: *Self, ctx: wayland.Context) void { ctx.display.registry.disable_object(self.handle); |