Refactor initialization and Context struct
I tried to make it a little bit easier to follow and get rid of the need to call back to context.x.y.z (as much) [I hope]
This commit is contained in:
parent
92e82f38f5
commit
30231f1149
8 changed files with 187 additions and 118 deletions
|
|
@ -30,7 +30,7 @@ fn outputListener(river_output_v1: *river.OutputV1, event: river.OutputV1.Event,
|
|||
switch (event) {
|
||||
.removed => {
|
||||
river_output_v1.destroy();
|
||||
output.context.allocator.destroy(output);
|
||||
utils.allocator.destroy(output);
|
||||
},
|
||||
.wl_output => {
|
||||
// log.debug("initializing new river_output_v1 corresponding to wl_output: {d}", .{ev.name});
|
||||
|
|
@ -61,6 +61,7 @@ const wayland = @import("wayland");
|
|||
const wl = wayland.client.wl;
|
||||
const river = wayland.client.river;
|
||||
|
||||
const Context = @import("main.zig").Context;
|
||||
const utils = @import("utils.zig");
|
||||
const Context = @import("Context.zig");
|
||||
|
||||
const log = std.log.scoped(.Output);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue