From e3521c2371c2d2c70c5d411c988fb19d2364d4f0 Mon Sep 17 00:00:00 2001 From: Dana Jansens Date: Fri, 1 Aug 2003 19:34:52 +0000 Subject: [PATCH] if a dock app has a button grabbed already then dont die --- openbox/grab.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/openbox/grab.c b/openbox/grab.c index 2d887784..67c15bec 100644 --- a/openbox/grab.c +++ b/openbox/grab.c @@ -120,9 +120,14 @@ void grab_button_full(guint button, guint state, Window win, guint mask, { guint i; + xerror_set_ignore(TRUE); /* can get BadAccess' from these */ + xerror_occured = FALSE; for (i = 0; i < MASK_LIST_SIZE; ++i) XGrabButton(ob_display, button, state | mask_list[i], win, FALSE, mask, pointer_mode, GrabModeSync, None, ob_cursor(cur)); + xerror_set_ignore(FALSE); + if (xerror_occured) + g_warning("failed to grab keycode %d modifiers %d", keycode, state); } void grab_button(guint button, guint state, Window win, guint mask) -- 2.45.2