Finish wiring up the TagOverlay
We had to fix a couple of compile errors that weren't showing while it wasn't wired up (since I never just tried to compile TagOverlay.zig on its own). We also changed the lifecycle to re-create/destroy the surface to show/hide it, similar to the way that river-tag-overlay actually did it. Finally, I added @branchHint(.cold) to a few places in the event loop where, if we're in the branch, the wm is definitely exiting, so it's fine if they're cold (should almost never happen).
This commit is contained in:
parent
2bef233d8f
commit
dbf32e793c
7 changed files with 158 additions and 23 deletions
|
|
@ -117,8 +117,8 @@ pub const TagOverlayConfig = struct {
|
|||
pub fn toTagOverlayOptions(self: TagOverlayConfig) TagOverlay.Options {
|
||||
return .{
|
||||
.border_width = self.border_width,
|
||||
.tag_amount = @intCast(std.math.clamp(@as(u32, self.tag_amount), 1, 32) - 1),
|
||||
.tags_per_row = @intCast(std.math.clamp(@as(u32, self.tags_per_row), 1, 32) - 1),
|
||||
.tag_amount = @intCast(std.math.clamp(@as(u32, self.tag_amount), 1, 32)),
|
||||
.tags_per_row = @intCast(std.math.clamp(@as(u32, self.tags_per_row), 1, 32)),
|
||||
.square_size = self.square_size,
|
||||
.square_inner_padding = self.square_inner_padding,
|
||||
.square_padding = self.square_padding,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue