aboutsummaryrefslogtreecommitdiff
path: root/include/commands.h
diff options
context:
space:
mode:
authortaiyu <taiyu.len@gmail.com>2015-09-22 09:41:32 -0700
committertaiyu <taiyu.len@gmail.com>2015-09-22 09:41:32 -0700
commit494499617090eccf73a0c75380ca884e77548a9f (patch)
tree46356ae7b43ce6a2ea133771784a072294918f78 /include/commands.h
parent6c33f8122a3c4bb8fc22129d1d2ad03f535885f7 (diff)
parent72aaffcf5b96f7d20438191e17c1df7174e52e66 (diff)
Merge branch 'master' of https://github.com/taiyu-len/sway
merge
Diffstat (limited to 'include/commands.h')
-rw-r--r--include/commands.h16
1 files changed, 9 insertions, 7 deletions
diff --git a/include/commands.h b/include/commands.h
index 5c87be51..1b4cd9ca 100644
--- a/include/commands.h
+++ b/include/commands.h
@@ -3,13 +3,15 @@
#include <stdbool.h>
#include "config.h"
-struct cmd_handler {
- char *command;
- enum cmd_status {
- CMD_SUCCESS,
- CMD_FAILURE,
- CMD_DEFER,
- } (*handle)(int argc, char **argv);
+
+enum cmd_status {
+ CMD_SUCCESS,
+ CMD_FAILURE,
+ CMD_INVALID,
+ CMD_DEFER,
+ // Config Blocks
+ CMD_BLOCK_END,
+ CMD_BLOCK_MODE,
};
enum cmd_status handle_command(char *command);