mirror of https://github.com/0intro/wmii
Fix ticket #16.
This commit is contained in:
parent
37146f5b85
commit
ff76a21c49
|
@ -485,7 +485,8 @@ client_focus(Client *c) {
|
|||
flushevents(FocusChangeMask, true);
|
||||
Dprint(DFocus, "client_focus([%C]%s) %ld\n", c, clientname(c), id);
|
||||
if(screen->focus != c) {
|
||||
Dprint(DFocus, "\t[%C]%s => [%C]%s\n", screen->focus, clientname(screen->focus),
|
||||
Dprint(DFocus, "\t[%C]%s => [%C]%s\n",
|
||||
screen->focus, clientname(screen->focus),
|
||||
c, clientname(c));
|
||||
if(c)
|
||||
setfocus(&c->w, RevertToParent);
|
||||
|
|
|
@ -106,6 +106,8 @@ float_placeframe(Frame *f) {
|
|||
*/
|
||||
vector_rpush(vp, a->r);
|
||||
for(ff=a->frame; ff; ff=ff->anext) {
|
||||
if(ff == f)
|
||||
continue;
|
||||
fr = ff->r;
|
||||
vp2->n = 0;
|
||||
for(i=0; i < vp->n; i++) {
|
||||
|
|
|
@ -179,12 +179,12 @@ bdown_event(Window *w, XButtonEvent *e) {
|
|||
if(!e->subwindow) {
|
||||
frame_restack(f, nil);
|
||||
view_restack(f->view);
|
||||
if(rect_haspoint_p(Pt(e->x, e->y), f->grabbox))
|
||||
mouse_movegrabbox(c);
|
||||
else if(f->area->floating)
|
||||
if(!e->subwindow && !rect_haspoint_p(Pt(e->x, e->y), f->titlebar))
|
||||
mouse_resize(c, quadrant(f->r, Pt(e->x_root, e->y_root)));
|
||||
}
|
||||
if(rect_haspoint_p(Pt(e->x, e->y), f->grabbox))
|
||||
mouse_movegrabbox(c);
|
||||
else if(f->area->floating)
|
||||
if(!e->subwindow && !rect_haspoint_p(Pt(e->x, e->y), f->titlebar))
|
||||
mouse_resize(c, quadrant(f->r, Pt(e->x_root, e->y_root)));
|
||||
|
||||
if(f->client != selclient())
|
||||
focus(c, false);
|
||||
|
|
|
@ -311,7 +311,9 @@ view_detach(Frame *f) {
|
|||
if(c->sel == f)
|
||||
c->sel = f->cnext;
|
||||
|
||||
if(v != screen->sel && empty_p(v))
|
||||
if(v == screen->sel)
|
||||
view_focus(screen, v);
|
||||
else if(empty_p(v))
|
||||
view_destroy(v);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue