From a24e3435b4eeaa31b51d7f8101a79ba56e1286cc Mon Sep 17 00:00:00 2001 From: Andrey Dotsenko <9fcc.dev@gmail.com> Date: Fri, 13 Apr 2018 07:35:41 +0300 Subject: [PATCH] Fix loosing focus while moving windows Windows which can't get focus (FALSE passed to gtk_window_set_accept_focus()) can grab it from active window while moving them. This behavior causes bugs in programs which use focus-in-event and focus-out-event combined with dialogs. --- openbox/moveresize.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/openbox/moveresize.c b/openbox/moveresize.c index d12a64de5..af953b3f5 100644 --- a/openbox/moveresize.c +++ b/openbox/moveresize.c @@ -226,10 +226,6 @@ void moveresize_start(ObClient *c, gint x, gint y, guint b, guint32 cnr) /* keep the pointer bounded to the screen for move/resize */ if (!grab_pointer(FALSE, TRUE, cur)) return; - if (!grab_keyboard()) { - ungrab_pointer(); - return; - } frame_end_iconify_animation(c->frame); @@ -311,7 +307,6 @@ void moveresize_start(ObClient *c, gint x, gint y, guint b, guint32 cnr) void moveresize_end(gboolean cancel) { - ungrab_keyboard(); ungrab_pointer(); popup_hide(popup);