changed main event loop
This commit is contained in:
parent
ee31e38dc7
commit
b6ad663f87
3 changed files with 21 additions and 10 deletions
13
event.c
13
event.c
|
@ -384,3 +384,16 @@ grabkeys()
|
|||
GrabModeAsync, GrabModeAsync);
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
procevent()
|
||||
{
|
||||
XEvent ev;
|
||||
|
||||
while(XPending(dpy)) {
|
||||
XNextEvent(dpy, &ev);
|
||||
if(handler[ev.type])
|
||||
(handler[ev.type])(&ev); /* call handler */
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue