aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/mapping.h
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2022-08-01 15:56:29 +0800
committerzeertzjq <zeertzjq@outlook.com>2022-08-01 21:54:18 +0800
commit8a032a686643305120f28baedb5613e3f286ae63 (patch)
tree3ef8c53d02a7c7904e84df19f845c297bf1d9f7f /src/nvim/mapping.h
parent9cebfbe6abf41cdbb501a3acf9857b1d34c1cffc (diff)
downloadrneovim-8a032a686643305120f28baedb5613e3f286ae63.tar.gz
rneovim-8a032a686643305120f28baedb5613e3f286ae63.tar.bz2
rneovim-8a032a686643305120f28baedb5613e3f286ae63.zip
vim-patch:8.2.5106: default cmdwin mappings are re-mappable
Problem: Default cmdwin mappings are re-mappable. Solution: Make the default mappings not re-mappable. (closes vim/vim#10580) Use symbols for the first do_map() argument. https://github.com/vim/vim/commit/44068e97dbd8fc8ebd93113e436a1e37a6bff52c
Diffstat (limited to 'src/nvim/mapping.h')
-rw-r--r--src/nvim/mapping.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/nvim/mapping.h b/src/nvim/mapping.h
index 98d0074075..7c48c3bce2 100644
--- a/src/nvim/mapping.h
+++ b/src/nvim/mapping.h
@@ -48,6 +48,11 @@ typedef struct map_arguments MapArguments;
#define MAP_ARGUMENTS_INIT { false, false, false, false, false, false, false, false, \
{ 0 }, 0, { 0 }, 0, NULL, 0, LUA_NOREF, false, NULL, 0, NULL }
+// Used for the first argument of do_map()
+#define MAPTYPE_MAP 0
+#define MAPTYPE_UNMAP 1
+#define MAPTYPE_NOREMAP 2
+
#ifdef INCLUDE_GENERATED_DECLARATIONS
# include "mapping.h.generated.h"
#endif