mirror of
https://github.com/swaywm/sway.git
synced 2026-04-20 06:47:03 -04:00
Keep tray separate
This commit is contained in:
parent
87a55dfe5c
commit
4d34bc393e
2 changed files with 5 additions and 1 deletions
|
|
@ -29,7 +29,9 @@ struct output {
|
||||||
char *name;
|
char *name;
|
||||||
int idx;
|
int idx;
|
||||||
bool focused;
|
bool focused;
|
||||||
|
#ifdef ENABLE_TRAY
|
||||||
bool active;
|
bool active;
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
struct workspace {
|
struct workspace {
|
||||||
|
|
|
||||||
|
|
@ -295,12 +295,14 @@ void bar_run(struct bar *bar) {
|
||||||
for (i = 0; i < bar->outputs->length; ++i) {
|
for (i = 0; i < bar->outputs->length; ++i) {
|
||||||
struct output *output = bar->outputs->items[i];
|
struct output *output = bar->outputs->items[i];
|
||||||
if (window_prerender(output->window) && output->window->cairo) {
|
if (window_prerender(output->window) && output->window->cairo) {
|
||||||
output->active = true;
|
|
||||||
render(output, bar->config, bar->status);
|
render(output, bar->config, bar->status);
|
||||||
window_render(output->window);
|
window_render(output->window);
|
||||||
wl_display_flush(output->registry->display);
|
wl_display_flush(output->registry->display);
|
||||||
|
#ifdef ENABLE_TRAY
|
||||||
|
output->active = true;
|
||||||
} else {
|
} else {
|
||||||
output->active = false;
|
output->active = false;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue