mirror of
https://github.com/tmux/tmux.git
synced 2025-01-11 18:58:47 +00:00
Ignore the user keys range when checking if a key is Unicode.
This commit is contained in:
parent
9f605178c3
commit
48eba4c195
2
status.c
2
status.c
@ -1471,8 +1471,6 @@ process_key:
|
|||||||
return (0);
|
return (0);
|
||||||
|
|
||||||
append_key:
|
append_key:
|
||||||
if (key <= 0x1f || (key >= KEYC_BASE && key < KEYC_BASE_END))
|
|
||||||
return (0);
|
|
||||||
if (key <= 0x7f)
|
if (key <= 0x7f)
|
||||||
utf8_set(&tmp, key);
|
utf8_set(&tmp, key);
|
||||||
else if (KEYC_IS_UNICODE(key))
|
else if (KEYC_IS_UNICODE(key))
|
||||||
|
4
tmux.h
4
tmux.h
@ -157,7 +157,9 @@ struct winlink;
|
|||||||
#define KEYC_IS_UNICODE(key) \
|
#define KEYC_IS_UNICODE(key) \
|
||||||
(((key) & KEYC_MASK_KEY) > 0x7f && \
|
(((key) & KEYC_MASK_KEY) > 0x7f && \
|
||||||
(((key) & KEYC_MASK_KEY) < KEYC_BASE || \
|
(((key) & KEYC_MASK_KEY) < KEYC_BASE || \
|
||||||
((key) & KEYC_MASK_KEY) >= KEYC_BASE_END))
|
((key) & KEYC_MASK_KEY) >= KEYC_BASE_END) && \
|
||||||
|
(((key) & KEYC_MASK_KEY) < KEYC_USER || \
|
||||||
|
((key) & KEYC_MASK_KEY) >= KEYC_USER + KEYC_NUSER))
|
||||||
|
|
||||||
/* Multiple click timeout. */
|
/* Multiple click timeout. */
|
||||||
#define KEYC_CLICK_TIMEOUT 300
|
#define KEYC_CLICK_TIMEOUT 300
|
||||||
|
Loading…
Reference in New Issue
Block a user