mirror of
https://codeberg.org/dwl/dwl.git
synced 2025-10-27 02:04:14 +00:00
hide-behind-fullscreen
This commit is contained in:
parent
4b8c1bf31e
commit
6ed051c5aa
@ -5,7 +5,7 @@ static const unsigned int borderpx = 1; /* border pixel of windows */
|
||||
static const float bordercolor[] = {0.5, 0.5, 0.5, 1.0};
|
||||
static const float focuscolor[] = {1.0, 0.0, 0.0, 1.0};
|
||||
/* To conform the xdg-protocol, set the alpha to zero to restore the old behavior */
|
||||
static const float fullscreen_bg[] = {0.1, 0.1, 0.1, 1.0};
|
||||
static const float fullscreen_bg[] = {0.1, 0.1, 0.1, 0.0};
|
||||
|
||||
/* tagging - tagcount must be no greater than 31 */
|
||||
static const int tagcount = 9;
|
||||
|
||||
18
dwl.c
18
dwl.c
@ -474,7 +474,9 @@ applyrules(Client *c)
|
||||
void
|
||||
arrange(Monitor *m)
|
||||
{
|
||||
Client *c;
|
||||
LayerSurface *l;
|
||||
Client *c, *sel = focustop(selmon);
|
||||
int i;
|
||||
wl_list_for_each(c, &clients, link)
|
||||
if (c->mon == m)
|
||||
wlr_scene_node_set_enabled(&c->scene->node, VISIBLEON(c, m));
|
||||
@ -484,6 +486,20 @@ arrange(Monitor *m)
|
||||
|
||||
strncpy(m->ltsymbol, m->lt[m->sellt]->symbol, LENGTH(m->ltsymbol));
|
||||
|
||||
if (sel && sel->isfullscreen && VISIBLEON(sel, m)) {
|
||||
for (i = 3; 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)
|
||||
wlr_scene_node_set_enabled(&c->scene->node, (sel->isfullscreen && c == sel)
|
||||
|| !sel->isfullscreen);
|
||||
}
|
||||
if (!sel || (!sel->isfullscreen && VISIBLEON(sel, m)))
|
||||
for (i = 3; 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);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user