]> Dogcows Code - chaz/openbox/blobdiff - openbox/actions/close.c
add the kill/close/cyclewindows actions
[chaz/openbox] / openbox / actions / close.c
diff --git a/openbox/actions/close.c b/openbox/actions/close.c
new file mode 100644 (file)
index 0000000..37260e1
--- /dev/null
@@ -0,0 +1,20 @@
+#include "openbox/actions.h"
+#include "openbox/client.h"
+
+static gboolean run_func(ObActionsData *data, gpointer options);
+
+void action_close_startup()
+{
+    actions_register("Close",
+                     NULL, NULL,
+                     run_func,
+                     NULL, NULL);
+}
+
+/* Always return FALSE because its not interactive */
+static gboolean run_func(ObActionsData *data, gpointer options)
+{
+    if (data->client) client_close(data->client);
+
+    return FALSE;
+}
This page took 0.023327 seconds and 4 git commands to generate.