Add focus to my single window
This commit is contained in:
parent
bad5007670
commit
9d64ca0124
5 changed files with 92 additions and 16 deletions
|
|
@ -28,8 +28,12 @@ pub fn init(output: *Output, context: *Context, river_output_v1: *river.OutputV1
|
|||
fn outputListener(river_output_v1: *river.OutputV1, event: river.OutputV1.Event, output: *Output) void {
|
||||
assert(output.output_v1 == river_output_v1);
|
||||
switch (event) {
|
||||
.wl_output => |ev| {
|
||||
log.debug("initializing new river_ouput_v1 corresponding to wl_output: {d}", .{ev.name});
|
||||
.removed => {
|
||||
river_output_v1.destroy();
|
||||
output.context.allocator.destroy(output);
|
||||
},
|
||||
.wl_output => {
|
||||
// log.debug("initializing new river_output_v1 corresponding to wl_output: {d}", .{ev.name});
|
||||
},
|
||||
.dimensions => |ev| {
|
||||
output.width = ev.width;
|
||||
|
|
@ -39,12 +43,17 @@ fn outputListener(river_output_v1: *river.OutputV1, event: river.OutputV1.Event,
|
|||
output.x = ev.x;
|
||||
output.y = ev.y;
|
||||
},
|
||||
else => |ev| {
|
||||
log.debug("unhandled event: {s}", .{@tagName(ev)});
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
pub fn manage(output: *Output) void {
|
||||
_ = output;
|
||||
}
|
||||
|
||||
pub fn render(output: *Output) void {
|
||||
_ = output;
|
||||
}
|
||||
|
||||
const std = @import("std");
|
||||
const assert = std.debug.assert;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue