diff options
author | sabetts <sabetts> | 2001-09-09 20:08:22 +0000 |
---|---|---|
committer | sabetts <sabetts> | 2001-09-09 20:08:22 +0000 |
commit | 7f7db7d9a35928480ff2f7ef77147ee48a35dc14 (patch) | |
tree | 9182c6a71d30ecb6350b4043c5a3e1e0e3cf30dc /src/main.c | |
parent | 29fc0a0b61524c858128dd5cc25d797182dd8a36 (diff) | |
download | ratpoison-7f7db7d9a35928480ff2f7ef77147ee48a35dc14.zip |
* src/split.c (set_active_frame): give the key_window focus when
no window has focus.
(blank_frame): give the key_window focus.
* src/main.c (init_screen): don't listen for keystrokes on the
root window.
(main): give the key_window focus in the case that no window has
focus.
Diffstat (limited to 'src/main.c')
-rw-r--r-- | src/main.c | 10 |
1 files changed, 7 insertions, 3 deletions
@@ -500,7 +500,12 @@ main (int argc, char *argv[]) /* Indicate to the user that ratpoison has booted. */ show_welcome_message(); - + + /* If no window has focus, give the key_window focus. */ + if (current_window() == NULL) + XSetInputFocus (dpy, current_screen()->key_window, + RevertToPointerRoot, CurrentTime); + handle_events (); return EXIT_SUCCESS; @@ -522,8 +527,7 @@ init_screen (screen_info *s, int screen_num) it, terminating ratpoison. */ XSelectInput(dpy, RootWindow (dpy, screen_num), PropertyChangeMask | ColormapChangeMask - | SubstructureRedirectMask | KeyPressMask | KeyReleaseMask - | SubstructureNotifyMask ); + | SubstructureRedirectMask | SubstructureNotifyMask ); XSync (dpy, False); s->screen_num = screen_num; |