tkeystrokes - plan9port - [fork] Plan 9 from user space
(HTM) git clone git://src.adamsgaard.dk/plan9port
(DIR) Log
(DIR) Files
(DIR) Refs
(DIR) README
(DIR) LICENSE
---
(DIR) commit df03d60c047a3010f800b26883763764be8d5744
(DIR) parent 7643b2635cb8f0688144ecf8e5b57b605258b6a7
(HTM) Author: rsc <devnull@localhost>
Date: Wed, 13 Jul 2005 10:53:20 +0000
keystrokes
Diffstat:
M src/cmd/rio/key.c | 1 +
M src/cmd/rio/main.c | 3 ++-
M src/cmd/rio/manage.c | 4 ++--
3 files changed, 5 insertions(+), 3 deletions(-)
---
(DIR) diff --git a/src/cmd/rio/key.c b/src/cmd/rio/key.c
t@@ -46,6 +46,7 @@ keypress(XKeyEvent *e)
/*
* process key press here
*/
+ if(0)
if(e->keycode == tabcode)
alttab(e->state&ShiftMask);
XAllowEvents(dpy, SyncKeyboard, e->time);
(DIR) diff --git a/src/cmd/rio/main.c b/src/cmd/rio/main.c
t@@ -335,7 +335,8 @@ initscreen(ScreenInfo *s, int i, int background)
attr.cursor = s->arrow;
attr.event_mask = SubstructureRedirectMask
| SubstructureNotifyMask | ColormapChangeMask
- | ButtonPressMask | ButtonReleaseMask | PropertyChangeMask;
+ | ButtonPressMask | ButtonReleaseMask | PropertyChangeMask |
+ KeyPressMask;
mask = CWCursor|CWEventMask;
XChangeWindowAttributes(dpy, s->root, mask, &attr);
XSync(dpy, False);
(DIR) diff --git a/src/cmd/rio/manage.c b/src/cmd/rio/manage.c
t@@ -26,7 +26,7 @@ manage(Client *c, int mapped)
XSetWindowAttributes attrs;
trace("manage", c, 0);
- XSelectInput(dpy, c->window, ColormapChangeMask | EnterWindowMask | PropertyChangeMask | FocusChangeMask);
+ XSelectInput(dpy, c->window, ColormapChangeMask | EnterWindowMask | PropertyChangeMask | FocusChangeMask | KeyPressMask);
/* Get loads of hints */
t@@ -138,7 +138,7 @@ manage(Client *c, int mapped)
CWBackPixel | CWBorderPixel | CWColormap,
&attrs);
- XSelectInput(dpy, c->parent, SubstructureRedirectMask | SubstructureNotifyMask|ButtonPressMask| PointerMotionMask|LeaveWindowMask);
+ XSelectInput(dpy, c->parent, SubstructureRedirectMask | SubstructureNotifyMask|ButtonPressMask| PointerMotionMask|LeaveWindowMask|KeyPressMask);
if(mapped)
c->reparenting = 1;
if(doreshape && !fixsize)