aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/map.c
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2022-07-07 07:42:22 +0800
committerGitHub <noreply@github.com>2022-07-07 07:42:22 +0800
commit4cded8cec13cb91ce97d6c505879123b8b892bb3 (patch)
tree3f949dbf090a62fe3ff206067cf0970a1fc83837 /src/nvim/map.c
parent5e84db5c90db60f68fe69b3585ba742d1a872b90 (diff)
parent03c9cf3feb0bdfdf4f6c1825440067b85a1fb619 (diff)
downloadrneovim-4cded8cec13cb91ce97d6c505879123b8b892bb3.tar.gz
rneovim-4cded8cec13cb91ce97d6c505879123b8b892bb3.tar.bz2
rneovim-4cded8cec13cb91ce97d6c505879123b8b892bb3.zip
Merge pull request #19180 from zeertzjq/tui-kitty-keypad
feat(tui): recognize keypad keys when using kitty keyboard protocol
Diffstat (limited to 'src/nvim/map.c')
-rw-r--r--src/nvim/map.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/nvim/map.c b/src/nvim/map.c
index d27e40b4ee..d3058a5d52 100644
--- a/src/nvim/map.c
+++ b/src/nvim/map.c
@@ -30,6 +30,8 @@
#define int_eq kh_int_hash_equal
#define handle_T_hash kh_int_hash_func
#define handle_T_eq kh_int_hash_equal
+#define KittyKey_hash kh_int_hash_func
+#define KittyKey_eq kh_int_hash_equal
#if defined(ARCH_64)
# define ptr_t_hash(key) uint64_t_hash((uint64_t)(key))
@@ -162,6 +164,7 @@ static inline bool ColorKey_eq(ColorKey ae1, ColorKey ae2)
}
MAP_IMPL(int, int, DEFAULT_INITIALIZER)
+MAP_IMPL(int, cstr_t, DEFAULT_INITIALIZER)
MAP_IMPL(cstr_t, ptr_t, DEFAULT_INITIALIZER)
MAP_IMPL(cstr_t, int, DEFAULT_INITIALIZER)
MAP_IMPL(ptr_t, ptr_t, DEFAULT_INITIALIZER)
@@ -177,6 +180,8 @@ MAP_IMPL(int, String, DEFAULT_INITIALIZER)
MAP_IMPL(ColorKey, ColorItem, COLOR_ITEM_INITIALIZER)
+MAP_IMPL(KittyKey, cstr_t, DEFAULT_INITIALIZER)
+
/// Deletes a key:value pair from a string:pointer map, and frees the
/// storage of both key and value.
///