1
0
Fork 0
forked from wry/wry

tree: fix per-workspace capture tracking

This commit is contained in:
Julian Orth 2024-04-20 13:30:34 +02:00
parent 670588fe4d
commit c6864a6d85
10 changed files with 191 additions and 145 deletions

View file

@ -132,11 +132,9 @@ impl Renderer<'_> {
x,
y,
);
let has_captures =
!output.screencasts.is_empty() || !output.global.pending_captures.is_empty();
let rd = output.render_data.borrow_mut();
if let Some(aw) = &rd.active_workspace {
let c = match has_captures && aw.captured {
let c = match aw.captured {
true => theme.colors.captured_focused_title_background.get(),
false => theme.colors.focused_title_background.get(),
};
@ -147,10 +145,7 @@ impl Renderer<'_> {
.fill_boxes2(slice::from_ref(&rd.underline), &c, x, y);
let c = theme.colors.unfocused_title_background.get();
self.base.fill_boxes2(&rd.inactive_workspaces, &c, x, y);
let c = match has_captures {
true => theme.colors.captured_unfocused_title_background.get(),
false => theme.colors.unfocused_title_background.get(),
};
let c = theme.colors.captured_unfocused_title_background.get();
self.base
.fill_boxes2(&rd.captured_inactive_workspaces, &c, x, y);
let c = theme.colors.attention_requested_background.get();