aboutsummaryrefslogtreecommitdiff
path: root/client-cmd.c
diff options
context:
space:
mode:
Diffstat (limited to 'client-cmd.c')
-rw-r--r--client-cmd.c17
1 files changed, 15 insertions, 2 deletions
diff --git a/client-cmd.c b/client-cmd.c
index 2d98d02d..62c84978 100644
--- a/client-cmd.c
+++ b/client-cmd.c
@@ -1,4 +1,4 @@
-/* $Id: client-cmd.c,v 1.6 2007-09-30 13:02:14 nicm Exp $ */
+/* $Id: client-cmd.c,v 1.7 2007-10-02 15:38:09 nicm Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
@@ -22,9 +22,10 @@
int client_cmd_prefix = META;
+int client_cmd_fn_msg(int, struct client_ctx *, char **);
int client_cmd_fn_select(int, struct client_ctx *, char **);
int client_cmd_fn_detach(int, struct client_ctx *, char **);
-int client_cmd_fn_msg(int, struct client_ctx *, char **);
+int client_cmd_fn_meta(int, struct client_ctx *, char **);
struct cmd {
int key;
@@ -59,6 +60,7 @@ struct cmd client_cmd_table[] = {
{ 'w', client_cmd_fn_msg, MSG_WINDOWLIST },
{ 'I', client_cmd_fn_msg, MSG_WINDOWINFO },
{ 'i', client_cmd_fn_msg, MSG_WINDOWINFO },
+ { META, client_cmd_fn_meta, 0 },
};
#define NCLIENTCMD (sizeof client_cmd_table / sizeof client_cmd_table[0])
@@ -104,3 +106,14 @@ client_cmd_fn_detach(
{
return (-1);
}
+
+/* Handle meta command. */
+int
+client_cmd_fn_meta(unused int arg, struct client_ctx *cctx, unused char **error)
+{
+ uint8_t key = META;
+
+ client_write_server(cctx, MSG_INPUT, &key, sizeof key);
+
+ return (0);
+}