]> Dogcows Code - chaz/openbox/blobdiff - openbox/action.c
disable the "Go there" menu entry when its the current desktop
[chaz/openbox] / openbox / action.c
index 483ac8dba349e3504681af6b5c2e0e995bf112cd..17d951cfe83dffcd29dbf21701c5e6c115fe3a3a 100644 (file)
@@ -395,7 +395,7 @@ void setup_action_showmenu(ObAction **a, ObUserAction uact)
        a time! */
     if (uact == OB_USER_ACTION_MENU_SELECTION) {
         action_unref(*a);
-        a = NULL;
+        *a = NULL;
     }
 }
 
@@ -817,7 +817,8 @@ ObAction *action_from_string(const gchar *name, ObUserAction uact)
             a = action_new(actionstrings[i].func);
             if (actionstrings[i].setup)
                 actionstrings[i].setup(&a, uact);
-            INTERACTIVE_LIMIT(a, uact);
+            if (a)
+                INTERACTIVE_LIMIT(a, uact);
             break;
         }
     if (!exist)
@@ -948,7 +949,12 @@ void action_run_list(GSList *acts, ObClient *c, ObFrameContext context,
                 if (!(cancel || done))
                     if (!keyboard_interactive_grab(state, a->data.any.c, a))
                         continue;
+            }
 
+            /* XXX UGLY HACK race with motion event starting a move and the
+               button release gettnig processed first. answer: don't queue
+               moveresize starts. UGLY HACK XXX */
+            if (a->data.any.interactive || a->func == action_moveresize) {
                 /* interactive actions are not queued */
                 a->func(&a->data);
             } else
@@ -980,6 +986,7 @@ void action_execute(union ActionData *data)
             if (!g_spawn_command_line_async(cmd, &e)) {
                 g_warning("failed to execute '%s': %s",
                           cmd, e->message);
+                g_error_free(e);
             }
             g_free(cmd);
         } else {
This page took 0.024201 seconds and 4 git commands to generate.