version 1.17, 2012/01/21 11:12:13 |
version 1.18, 2012/07/11 07:10:15 |
|
|
* List key bindings. |
* List key bindings. |
*/ |
*/ |
|
|
int cmd_list_keys_exec(struct cmd *, struct cmd_ctx *); |
enum cmd_retval cmd_list_keys_exec(struct cmd *, struct cmd_ctx *); |
|
enum cmd_retval cmd_list_keys_table(struct cmd *, struct cmd_ctx *); |
|
|
int cmd_list_keys_table(struct cmd *, struct cmd_ctx *); |
|
|
|
const struct cmd_entry cmd_list_keys_entry = { |
const struct cmd_entry cmd_list_keys_entry = { |
"list-keys", "lsk", |
"list-keys", "lsk", |
"t:", 0, 0, |
"t:", 0, 0, |
|
|
cmd_list_keys_exec |
cmd_list_keys_exec |
}; |
}; |
|
|
int |
enum cmd_retval |
cmd_list_keys_exec(struct cmd *self, struct cmd_ctx *ctx) |
cmd_list_keys_exec(struct cmd *self, struct cmd_ctx *ctx) |
{ |
{ |
struct args *args = self->args; |
struct args *args = self->args; |
|
|
ctx->print(ctx, "bind-key %s", tmp); |
ctx->print(ctx, "bind-key %s", tmp); |
} |
} |
|
|
return (0); |
return (CMD_RETURN_NORMAL); |
} |
} |
|
|
int |
int |
|
|
tablename = args_get(args, 't'); |
tablename = args_get(args, 't'); |
if ((mtab = mode_key_findtable(tablename)) == NULL) { |
if ((mtab = mode_key_findtable(tablename)) == NULL) { |
ctx->error(ctx, "unknown key table: %s", tablename); |
ctx->error(ctx, "unknown key table: %s", tablename); |
return (-1); |
return (CMD_RETURN_ERROR); |
} |
} |
|
|
width = 0; |
width = 0; |
|
|
} |
} |
} |
} |
|
|
return (0); |
return (CMD_RETURN_NORMAL); |
} |
} |