]> Dogcows Code - chaz/openbox/commitdiff
ungrab only as many times as we grabbed
authorDana Jansens <danakj@orodu.net>
Thu, 4 Sep 2003 00:39:05 +0000 (00:39 +0000)
committerDana Jansens <danakj@orodu.net>
Thu, 4 Sep 2003 00:39:05 +0000 (00:39 +0000)
openbox/keyboard.c

index 1f509f77ff8c5e61aa0544690053f95faea16b3d..cef0dfd68364179545010102d024c43a8b416e56 100644 (file)
@@ -186,12 +186,15 @@ gboolean keyboard_process_interactive_grab(const XEvent *e,
 
             s->action->func(&s->action->data);
 
-            grab_keyboard(FALSE);
-            grab_pointer(FALSE, OB_CURSOR_NONE);
-            keyboard_reset_chains();
-
             g_free(s);
+
             interactive_states = g_slist_delete_link(interactive_states, it);
+            if (!interactive_states) {
+                grab_keyboard(FALSE);
+                grab_pointer(FALSE, OB_CURSOR_NONE);
+                keyboard_reset_chains();
+            }
+
             handled = TRUE;
         }
     }
This page took 0.022728 seconds and 4 git commands to generate.