version 1.54, 2015/11/05 11:05:30 |
version 1.55, 2015/11/12 11:05:34 |
|
|
int |
int |
key_bindings_cmp(struct key_binding *bd1, struct key_binding *bd2) |
key_bindings_cmp(struct key_binding *bd1, struct key_binding *bd2) |
{ |
{ |
return (bd1->key - bd2->key); |
if (bd1->key < bd2->key) |
|
return (-1); |
|
if (bd1->key > bd2->key) |
|
return (1); |
|
return (0); |
} |
} |
|
|
struct key_table * |
struct key_table * |
|
|
} |
} |
|
|
void |
void |
key_bindings_add(const char *name, int key, int can_repeat, |
key_bindings_add(const char *name, key_code key, int can_repeat, |
struct cmd_list *cmdlist) |
struct cmd_list *cmdlist) |
{ |
{ |
struct key_table *table; |
struct key_table *table; |
|
|
} |
} |
|
|
void |
void |
key_bindings_remove(const char *name, int key) |
key_bindings_remove(const char *name, key_code key) |
{ |
{ |
struct key_table *table; |
struct key_table *table; |
struct key_binding bd_find, *bd; |
struct key_binding bd_find, *bd; |