mirror of
https://github.com/tiyn/dwl.git
synced 2025-11-13 05:49:45 +01:00
merged hide-behind-fullscreen
This commit is contained in:
24
dwl.c
24
dwl.c
@@ -599,7 +599,9 @@ applyrules(Client *c)
|
||||
void
|
||||
arrange(Monitor *m)
|
||||
{
|
||||
Client *c;
|
||||
LayerSurface *l;
|
||||
Client *c, *sel = focustop(m, 0);
|
||||
int i;
|
||||
|
||||
if (!m->wlr_output->enabled)
|
||||
return;
|
||||
@@ -630,6 +632,26 @@ arrange(Monitor *m)
|
||||
: c->scene->node.parent);
|
||||
}
|
||||
|
||||
if (sel && sel->isfullscreen && VISIBLEON(sel, m)) {
|
||||
for (i = 2; i > ZWLR_LAYER_SHELL_V1_LAYER_BACKGROUND; i--) {
|
||||
wl_list_for_each(l, &sel->mon->layers[i], link)
|
||||
wlr_scene_node_set_enabled(&l->scene->node, 0);
|
||||
}
|
||||
|
||||
wl_list_for_each(c, &clients, link) {
|
||||
if (c->mon != m)
|
||||
continue;
|
||||
wlr_scene_node_set_enabled(&c->scene->node, (sel->isfullscreen && c == sel)
|
||||
|| !sel->isfullscreen);
|
||||
}
|
||||
}
|
||||
if (!sel || (!sel->isfullscreen && VISIBLEON(sel, m))) {
|
||||
for (i = 2; i > ZWLR_LAYER_SHELL_V1_LAYER_BACKGROUND; i--) {
|
||||
wl_list_for_each(l, &m->layers[i], link)
|
||||
wlr_scene_node_set_enabled(&l->scene->node, 1);
|
||||
}
|
||||
}
|
||||
|
||||
if (m->lt[m->sellt]->arrange)
|
||||
m->lt[m->sellt]->arrange(m);
|
||||
motionnotify(0, NULL, 0, 0, 0, 0);
|
||||
|
||||
Reference in New Issue
Block a user