diff options
author | nicm <nicm> | 2020-05-16 16:35:13 +0000 |
---|---|---|
committer | nicm <nicm> | 2020-05-16 16:35:13 +0000 |
commit | 292b335ca5b594729cf9ff79f0f4273c725537a4 (patch) | |
tree | 0eec72b4ead11b18a656536d517ca119e89c9dea /mode-tree.c | |
parent | e2a26740b9880d0066c8a04ca2d7202e7f99bd07 (diff) | |
download | rtmux-292b335ca5b594729cf9ff79f0f4273c725537a4.tar.gz rtmux-292b335ca5b594729cf9ff79f0f4273c725537a4.tar.bz2 rtmux-292b335ca5b594729cf9ff79f0f4273c725537a4.zip |
Separate key flags and modifiers, log key flags, make the "xterm" flag
more explicit and fix M- keys with a leading escape.
Diffstat (limited to 'mode-tree.c')
-rw-r--r-- | mode-tree.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/mode-tree.c b/mode-tree.c index a523478e..993070ec 100644 --- a/mode-tree.c +++ b/mode-tree.c @@ -987,7 +987,7 @@ mode_tree_key(struct mode_tree_data *mtd, struct client *c, key_code *key, choice = -1; if (*key >= '0' && *key <= '9') choice = (*key) - '0'; - else if (((*key) & KEYC_MASK_MOD) == KEYC_ESCAPE) { + else if (((*key) & KEYC_MASK_MODIFIERS) == KEYC_META) { tmp = (*key) & KEYC_MASK_KEY; if (tmp >= 'a' && tmp <= 'z') choice = 10 + (tmp - 'a'); @@ -1111,12 +1111,12 @@ mode_tree_key(struct mode_tree_data *mtd, struct client *c, key_code *key, mode_tree_build(mtd); } break; - case '-'|KEYC_ESCAPE: + case '-'|KEYC_META: TAILQ_FOREACH(mti, &mtd->children, entry) mti->expanded = 0; mode_tree_build(mtd); break; - case '+'|KEYC_ESCAPE: + case '+'|KEYC_META: TAILQ_FOREACH(mti, &mtd->children, entry) mti->expanded = 1; mode_tree_build(mtd); |