[hackers] [wmii] Don't replay clicks that were on the frame window.

From: Kris Maglione <jg_AT_suckless.org>
Date: Thu Feb 22 21:12:45 2007

changeset: 1932:6b20360e5904
tag: tip
user: Kris Maglione <jg_AT_suckless.org>
date: Thu Feb 22 15:12:36 2007 -0500
summary: Don't replay clicks that were on the frame window.

diff -r 14dfa6ca7bdf -r 6b20360e5904 event.c
--- a/event.c Thu Feb 22 15:06:59 2007 -0500
+++ b/event.c Thu Feb 22 15:12:36 2007 -0500
@@ -63,7 +63,7 @@ buttonpress(XEvent *e) {
                                 focus(f->client, True);
                                 break;
                         default: break;
- XAllowEvents(blz.dpy, ReplayPointer, CurrentTime);
+ XAllowEvents(blz.dpy, ReplayPointer, ev->time);
                         }
                 }else{
                         if(ev->button == Button1) {
@@ -78,10 +78,13 @@ buttonpress(XEvent *e) {
                                 if(f->client != sel_client())
                                         focus(f->client, True);
                         }
- XAllowEvents(blz.dpy, ReplayPointer, CurrentTime);
+ if(ev->subwindow)
+ XAllowEvents(blz.dpy, ReplayPointer, ev->time);
+ else
+ XAllowEvents(blz.dpy, AsyncPointer, ev->time);
                 }
         }else
- XAllowEvents(blz.dpy, ReplayPointer, CurrentTime);
+ XAllowEvents(blz.dpy, ReplayPointer, ev->time);
 }
 
 static void
Received on Thu Feb 22 2007 - 21:12:45 UTC

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