nsxiv75b143a
Return value != 0 on Escape
+3 −0
1 file changed
- M events.c +3 −0
| @@ -47,6 +47,9 @@ void on_keypress(app_t *app, XEvent *ev) { | |||
| 47 | 47 | keysym = XKeycodeToKeysym(dpy, (KeyCode) kev->keycode, 0); | |
| 48 | 48 | ||
| 49 | 49 | switch (keysym) { | |
| 50 | + | case XK_Escape: | |
| 51 | + | app_quit(app); | |
| 52 | + | exit(1); | |
| 50 | 53 | case XK_q: | |
| 51 | 54 | app_quit(app); | |
| 52 | 55 | exit(0); | |