diff --git a/river/SeatStatus.zig b/river/SeatStatus.zig index 9bcd4ac..07debbb 100644 --- a/river/SeatStatus.zig +++ b/river/SeatStatus.zig @@ -81,8 +81,12 @@ pub fn sendFocusedView(seat_status: SeatStatus) void { if (seat_status.seat_status_v1.getVersion() >= 4) { switch (seat_status.seat.focused) { .view => |view| { - //assert(view.inflight.tags == view.current.tags); - seat_status.seat_status_v1.sendFocusedView(view.getTitle() orelse "", view.current.tags); + if (view.current.tags != 0) { + // A view can't be on no tags, so we need to wait for the + // layout to update. There is probably a better way to do + // this, but this way seems to work. + seat_status.seat_status_v1.sendFocusedView(view.getTitle() orelse "", view.current.tags); + } }, else => seat_status.seat_status_v1.sendFocusedView("", 0), }