Fix resize at removing fullscreen state with free clients
This commit is contained in:
parent
7dd2bcaec9
commit
8ba39d3960
20
src/client.h
20
src/client.h
@ -186,5 +186,25 @@ clients_tag_arrange_map(struct tag *t)
|
|||||||
sfunc(c);
|
sfunc(c);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static inline struct client*
|
||||||
|
client_get_larger(struct tag *t)
|
||||||
|
{
|
||||||
|
struct client *c, *lc = NULL;
|
||||||
|
int tmp, l = 0;
|
||||||
|
|
||||||
|
FOREACH_NFCLIENT(c, &t->clients, tnext)
|
||||||
|
{
|
||||||
|
if((tmp = (c->geo.w + c->geo.h)) > l)
|
||||||
|
{
|
||||||
|
l = tmp;
|
||||||
|
lc = c;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if(lc && (lc->flags & CLIENT_TABBED))
|
||||||
|
lc = lc->tabmaster;
|
||||||
|
|
||||||
|
return lc;
|
||||||
|
}
|
||||||
|
|
||||||
#endif /* CLIENT_H */
|
#endif /* CLIENT_H */
|
||||||
|
|||||||
@ -220,7 +220,10 @@ ewmh_manage_state(long data[], struct client *c)
|
|||||||
(unsigned char*)0, 0);
|
(unsigned char*)0, 0);
|
||||||
XReparentWindow(W->dpy, c->win, c->frame, c->wgeo.x, c->wgeo.y);
|
XReparentWindow(W->dpy, c->win, c->frame, c->wgeo.x, c->wgeo.y);
|
||||||
|
|
||||||
layout_fix_hole(c);
|
if(c->flags & CLIENT_FREE)
|
||||||
|
client_moveresize(c, &c->geo);
|
||||||
|
else
|
||||||
|
layout_fix_hole(c);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
11
src/layout.c
11
src/layout.c
@ -370,10 +370,15 @@ layout_split_integrate(struct client *c, struct client *sc)
|
|||||||
struct geo g;
|
struct geo g;
|
||||||
bool f = false;
|
bool f = false;
|
||||||
|
|
||||||
/* No sc or not compatible sc */
|
/* No sc or not compatible sc to integrate in */
|
||||||
if(!sc || sc == c || sc->tag != c->tag
|
if(!sc
|
||||||
|| sc->flags & CLIENT_FREE)
|
|| sc == c
|
||||||
|
|| sc->tag != c->tag
|
||||||
|
|| (sc->flags & CLIENT_FREE))
|
||||||
{
|
{
|
||||||
|
/* Larger tiled one?
|
||||||
|
if(!(sc = client_get_larger(c->tag)) || sc == c)*/
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* check for the first tiled client or
|
* check for the first tiled client or
|
||||||
* maximize the lonely client
|
* maximize the lonely client
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user