diff --git a/src/Context.zig b/src/Context.zig index 5c035b5..c7f59d2 100644 --- a/src/Context.zig +++ b/src/Context.zig @@ -16,7 +16,6 @@ wl_registry: *wl.Registry, wl_shm: *wl.Shm, river_layer_shell_v1: *river.LayerShellV1, -zwlr_layer_shell_v1: *zwlr.LayerShellV1, // Wayland globals that we have special structs for im: *InputManager, @@ -54,7 +53,6 @@ pub const Options = struct { river_window_manager_v1: *river.WindowManagerV1, river_xkb_bindings_v1: *river.XkbBindingsV1, - zwlr_layer_shell_v1: *zwlr.LayerShellV1, config: *Config, }; @@ -83,7 +81,6 @@ pub fn create(options: Options) !*Context { .wl_registry = options.wl_registry, .wl_shm = options.wl_shm, .river_layer_shell_v1 = options.river_layer_shell_v1, - .zwlr_layer_shell_v1 = options.zwlr_layer_shell_v1, .wallpaper_image = loadWallpaperImage(options.config), .im = im, .wm = wm, @@ -107,7 +104,6 @@ pub fn destroy(context: *Context) void { // Destroy Wayland globals context.river_layer_shell_v1.destroy(); - context.zwlr_layer_shell_v1.destroy(); context.wl_shm.destroy(); context.wl_compositor.destroy(); context.wl_registry.destroy(); @@ -262,7 +258,6 @@ const process = std.process; const wayland = @import("wayland"); const river = wayland.client.river; const wl = wayland.client.wl; -const zwlr = wayland.client.zwlr; const utils = @import("utils.zig"); const Bar = @import("Bar.zig"); diff --git a/src/Output.zig b/src/Output.zig index 41ca2a0..c0289fb 100644 --- a/src/Output.zig +++ b/src/Output.zig @@ -642,7 +642,6 @@ const DoublyLinkedList = std.DoublyLinkedList; const wayland = @import("wayland"); const wl = wayland.client.wl; const river = wayland.client.river; -const zwlr = wayland.client.zwlr; const utils = @import("utils.zig"); const Rect = utils.Rect; diff --git a/src/main.zig b/src/main.zig index 7e7af13..aec0c10 100644 --- a/src/main.zig +++ b/src/main.zig @@ -12,7 +12,6 @@ const Globals = struct { wl_compositor: ?*wl.Compositor = null, wl_shm: ?*wl.Shm = null, - zwlr_layer_shell_v1: ?*zwlr.LayerShellV1 = null, }; const usage: []const u8 = @@ -67,8 +66,6 @@ pub fn main() !void { const river_window_manager_v1 = globals.river_window_manager_v1 orelse utils.interfaceNotAdvertised(river.WindowManagerV1); const river_xkb_bindings_v1 = globals.river_xkb_bindings_v1 orelse utils.interfaceNotAdvertised(river.XkbBindingsV1); - const zwlr_layer_shell_v1 = globals.zwlr_layer_shell_v1 orelse utils.interfaceNotAdvertised(zwlr.LayerShellV1); - const config = try Config.create(); defer config.destroy(); const context = try Context.create(.{ @@ -81,7 +78,6 @@ pub fn main() !void { .river_layer_shell_v1 = river_layer_shell_v1, .river_window_manager_v1 = river_window_manager_v1, .river_xkb_bindings_v1 = river_xkb_bindings_v1, - .zwlr_layer_shell_v1 = zwlr_layer_shell_v1, .config = config, }); defer context.destroy(); @@ -273,11 +269,6 @@ fn registryListener(registry: *wl.Registry, event: wl.Registry.Event, globals: * globals.river_xkb_bindings_v1 = registry.bind(ev.name, river.XkbBindingsV1, 2) catch |e| { fatal("Failed to bind to river_xkb_bindings_v1: {any}", .{@errorName(e)}); }; - } else if (mem.orderZ(u8, ev.interface, zwlr.LayerShellV1.interface.name) == .eq) { - if (ev.version < 3) utils.versionNotSupported(zwlr.LayerShellV1, ev.version, 3); - globals.zwlr_layer_shell_v1 = registry.bind(ev.name, zwlr.LayerShellV1, 3) catch |e| { - fatal("Failed to bind to zwlr_layer_shell_v1: {any}", .{@errorName(e)}); - }; } }, .global_remove => |_| { @@ -335,7 +326,6 @@ const time = std.time; const wayland = @import("wayland"); const river = wayland.client.river; const wl = wayland.client.wl; -const zwlr = wayland.client.zwlr; const fcft = @import("fcft"); const flags = @import("flags.zig");