[hackers] [wmii] Fixed a bug where focus reverted to None when the last client of a tag was XKilled

From: Kris Maglione <jg_AT_suckless.org>
Date: Wed Feb 21 05:50:36 2007

changeset: 1922:a14c395d4f53
tag: tip
user: Kris Maglione <jg_AT_suckless.org>
date: Tue Feb 20 23:49:36 2007 -0500
summary: Fixed a bug where focus reverted to None when the last client of a tag was XKilled

diff -r 4e6e76f5739e -r a14c395d4f53 event.c
--- a/event.c Tue Feb 20 22:18:21 2007 -0500
+++ b/event.c Tue Feb 20 23:49:36 2007 -0500
@@ -291,6 +291,12 @@ focusin(XEvent *e) {
         Client *c, *old;
         XFocusChangeEvent *ev = &e->xfocus;
 
+ /* Yes, we're focusing in on nothing, here. */
+ if(ev->detail == NotifyDetailNone) {
+ XSetInputFocus(blz.dpy, screen->barwin, RevertToParent, CurrentTime);
+ return;
+ }
+
         if(!((ev->detail == NotifyNonlinear)
            ||(ev->detail == NotifyNonlinearVirtual)
            ||(ev->detail == NotifyInferior)
diff -r 4e6e76f5739e -r a14c395d4f53 fs.c
--- a/fs.c Tue Feb 20 22:18:21 2007 -0500
+++ b/fs.c Tue Feb 20 23:49:36 2007 -0500
@@ -786,7 +786,7 @@ fs_write(P9Req *r) {
                 respond(r, nil);
                 return;
         }
- /* This is an assert because it should this should not be called if
+ /* This is an assert because this function should not be called if
          * the file is not open for writing. */
         assert(!"Write called on an unwritable file");
 }
Received on Wed Feb 21 2007 - 05:50:36 UTC

This archive was generated by hypermail 2.2.0 : Sun Jul 13 2008 - 15:55:35 UTC