only grab keybinds on the root window, not every client window
This commit is contained in:
parent
23a43c5a40
commit
fb2493115f
4 changed files with 2 additions and 12 deletions
|
@ -374,7 +374,6 @@ void client_manage(Window window)
|
||||||
self->window, newx, newy, self->area.width, self->area.height);
|
self->window, newx, newy, self->area.width, self->area.height);
|
||||||
client_apply_startup_state(self, newx, newy);
|
client_apply_startup_state(self, newx, newy);
|
||||||
|
|
||||||
keyboard_grab_for_client(self, TRUE);
|
|
||||||
mouse_grab_for_client(self, TRUE);
|
mouse_grab_for_client(self, TRUE);
|
||||||
|
|
||||||
if (activate) {
|
if (activate) {
|
||||||
|
@ -490,7 +489,6 @@ void client_unmanage(ObClient *self)
|
||||||
event_ignore_queued_enters();
|
event_ignore_queued_enters();
|
||||||
}
|
}
|
||||||
|
|
||||||
keyboard_grab_for_client(self, FALSE);
|
|
||||||
mouse_grab_for_client(self, FALSE);
|
mouse_grab_for_client(self, FALSE);
|
||||||
|
|
||||||
/* remove the window from our save set */
|
/* remove the window from our save set */
|
||||||
|
|
|
@ -589,7 +589,7 @@ static void event_process(const XEvent *ec, gpointer data)
|
||||||
mouse_event(client, e);
|
mouse_event(client, e);
|
||||||
} else if (e->type == KeyPress) {
|
} else if (e->type == KeyPress) {
|
||||||
keyboard_event((focus_cycle_target ? focus_cycle_target :
|
keyboard_event((focus_cycle_target ? focus_cycle_target :
|
||||||
client), e);
|
(client ? client : focus_client)), e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -68,18 +68,12 @@ static void grab_for_window(Window win, gboolean grab)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void keyboard_grab_for_client(ObClient *c, gboolean grab)
|
|
||||||
{
|
|
||||||
grab_for_window(c->window, grab);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void grab_keys(gboolean grab)
|
static void grab_keys(gboolean grab)
|
||||||
{
|
{
|
||||||
GList *it;
|
GList *it;
|
||||||
|
|
||||||
grab_for_window(screen_support_win, grab);
|
grab_for_window(screen_support_win, grab);
|
||||||
for (it = client_list; it; it = g_list_next(it))
|
grab_for_window(RootWindow(ob_display, ob_screen), grab);
|
||||||
grab_for_window(((ObClient*)it->data)->window, grab);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static gboolean chain_timeout(gpointer data)
|
static gboolean chain_timeout(gpointer data)
|
||||||
|
|
|
@ -46,6 +46,4 @@ gboolean keyboard_process_interactive_grab(const XEvent *e,
|
||||||
struct _ObClient **client);
|
struct _ObClient **client);
|
||||||
gboolean keyboard_interactively_grabbed();
|
gboolean keyboard_interactively_grabbed();
|
||||||
|
|
||||||
void keyboard_grab_for_client(struct _ObClient *c, gboolean grab);
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in a new issue