mirror of https://github.com/0intro/wmii
Try harder to find the right screen for new fullscreen windows. Closes issue #164.
This commit is contained in:
parent
3083118201
commit
48ee811677
|
@ -609,6 +609,7 @@ client_kill(Client *c, bool nice) {
|
|||
|
||||
void
|
||||
fullscreen(Client *c, int fullscreen, long screen) {
|
||||
Client *leader;
|
||||
Frame *f;
|
||||
bool wassel;
|
||||
|
||||
|
@ -638,7 +639,16 @@ fullscreen(Client *c, int fullscreen, long screen) {
|
|||
}
|
||||
}
|
||||
else {
|
||||
c->fullscreen = screen >= 0 ? screen : ownerscreen(c->r);
|
||||
c->fullscreen = 0;
|
||||
if(screen >= 0)
|
||||
c->fullscreen = screen;
|
||||
else if(c->sel)
|
||||
c->fullscreen = ownerscreen(c->r);
|
||||
else if(c->group && (leader = group_leader(c->group)) && leader->sel)
|
||||
c->fullscreen = ownerscreen(leader->r);
|
||||
else if(selclient())
|
||||
c->fullscreen = ownerscreen(selclient()->r);
|
||||
|
||||
for(f=c->frame; f; f=f->cnext)
|
||||
f->oldarea = -1;
|
||||
if((f = c->sel))
|
||||
|
@ -758,11 +768,11 @@ updatemwm(Client *c) {
|
|||
|
||||
c->borderless = 0;
|
||||
c->titleless = 0;
|
||||
if(n >= 3 && (ret[Flags]&FlagDecor)) {
|
||||
if(ret[Decor]&All)
|
||||
if(n >= 3 && (ret[Flags] & FlagDecor)) {
|
||||
if(ret[Decor] & All)
|
||||
ret[Decor] ^= ~0;
|
||||
c->borderless = !(ret[Decor]&Border);
|
||||
c->titleless = !(ret[Decor]&Title);
|
||||
c->borderless = !(ret[Decor] & Border);
|
||||
c->titleless = !(ret[Decor] & Title);
|
||||
}
|
||||
free(ret);
|
||||
|
||||
|
@ -826,7 +836,7 @@ client_prop(Client *c, Atom a) {
|
|||
update_class(c);
|
||||
break;
|
||||
case XA_WM_NAME:
|
||||
wmname:
|
||||
wmname:
|
||||
client_updatename(c);
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -183,12 +183,12 @@ struct Client {
|
|||
uint border;
|
||||
int fullscreen;
|
||||
int unmapped;
|
||||
char floating;
|
||||
char fixedsize;
|
||||
char urgent;
|
||||
char borderless;
|
||||
char titleless;
|
||||
char noinput;
|
||||
bool floating;
|
||||
bool fixedsize;
|
||||
bool urgent;
|
||||
bool borderless;
|
||||
bool titleless;
|
||||
bool noinput;
|
||||
};
|
||||
|
||||
struct Divide {
|
||||
|
|
Loading…
Reference in New Issue