mirror of
https://github.com/0intro/wmii
synced 2024-11-21 21:31:33 +03:00
Skip non-focusable windows on select up/down.
This commit is contained in:
parent
b5ed1df3a1
commit
b986944d7a
@ -192,29 +192,31 @@ Frame*
|
||||
stack_find(Area *a, Frame *f, int dir, bool stack) {
|
||||
Frame *fp;
|
||||
|
||||
#define predicate(f) !((f)->collapsed && stack || (f)->client->nofocus)
|
||||
switch (dir) {
|
||||
default:
|
||||
die("not reached");
|
||||
case North:
|
||||
if(f)
|
||||
for(f=f->aprev; f && f->collapsed && stack; f=f->aprev)
|
||||
for(f=f->aprev; f && !predicate(f); f=f->aprev)
|
||||
;
|
||||
else {
|
||||
f = nil;
|
||||
for(fp=a->frame; fp; fp=fp->anext)
|
||||
if(!fp->collapsed || !stack)
|
||||
if(predicate(fp))
|
||||
f = fp;
|
||||
}
|
||||
break;
|
||||
case South:
|
||||
if(f)
|
||||
for(f=f->anext; f && f->collapsed && stack; f=f->anext)
|
||||
for(f=f->anext; f && !predicate(f); f=f->anext)
|
||||
;
|
||||
else
|
||||
for(f=a->frame; f && f->collapsed && stack; f=f->anext)
|
||||
for(f=a->frame; f && !predicate(f); f=f->anext)
|
||||
;
|
||||
break;
|
||||
}
|
||||
#undef predicate
|
||||
return f;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user