From 98c86118ca941d71c0c511c865d5913814012aed Mon Sep 17 00:00:00 2001 From: Dana Jansens Date: Fri, 12 Feb 2010 13:31:49 -0500 Subject: [PATCH] have obt refresh the xlib keyboard stuff on mappingnotify events --- obt/mainloop.c | 3 +++ openbox/event.c | 1 - 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/obt/mainloop.c b/obt/mainloop.c index bf866ae..ebc9e96 100644 --- a/obt/mainloop.c +++ b/obt/mainloop.c @@ -300,6 +300,9 @@ void obt_main_loop_run(ObtMainLoop *loop) do { XNextEvent(loop->display, &e); + if (e.type == MappingNotify) + XRefreshKeyboardMapping(&e.xmapping); + for (it = loop->x_handlers; it; it = g_slist_next(it)) { ObtMainLoopXHandlerType *h = it->data; h->func(&e, h->data); diff --git a/openbox/event.c b/openbox/event.c index 13fd311..44a90f9 100644 --- a/openbox/event.c +++ b/openbox/event.c @@ -638,7 +638,6 @@ static void event_process(const XEvent *ec, gpointer data) modifier map, and rebind all the key bindings as appropriate */ ob_debug("Keyboard map changed. Reloading keyboard bindings."); ob_set_state(OB_STATE_RECONFIGURING); - XRefreshKeyboardMapping(&e->xmapping); obt_keyboard_reload(); keyboard_rebind(); ob_set_state(OB_STATE_RUNNING); -- 1.9.1