diff options
author | ZviRackover <zvirack@gmail.com> | 2018-09-02 00:58:30 +0300 |
---|---|---|
committer | ZviRackover <zvirack@gmail.com> | 2018-09-09 10:45:50 +0300 |
commit | cbdbc4f63d68a6b17b9eea5c67130e37d3d0f278 (patch) | |
tree | 5d82993e830a807647ec81aad1d5a391e4490cb0 /src/nvim/keymap.c | |
parent | 50eadfe2e991a0bb5fe0f98377d91702f0a20492 (diff) | |
download | rneovim-cbdbc4f63d68a6b17b9eea5c67130e37d3d0f278.tar.gz rneovim-cbdbc4f63d68a6b17b9eea5c67130e37d3d0f278.tar.bz2 rneovim-cbdbc4f63d68a6b17b9eea5c67130e37d3d0f278.zip |
Refactor: Remove occurences of mb_char2bytes
Diffstat (limited to 'src/nvim/keymap.c')
-rw-r--r-- | src/nvim/keymap.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/nvim/keymap.c b/src/nvim/keymap.c index 3cc74c0044..fad4722661 100644 --- a/src/nvim/keymap.c +++ b/src/nvim/keymap.c @@ -466,7 +466,7 @@ char_u *get_special_key_name(int c, int modifiers) /* Not a special key, only modifiers, output directly */ else { if (has_mbyte && (*mb_char2len)(c) > 1) - idx += (*mb_char2bytes)(c, string + idx); + idx += utf_char2bytes(c, string + idx); else if (vim_isprintc(c)) string[idx++] = (char_u)c; else { @@ -525,7 +525,7 @@ unsigned int trans_special(const char_u **srcp, const size_t src_len, dst[dlen++] = (char_u)KEY2TERMCAP0(key); dst[dlen++] = KEY2TERMCAP1(key); } else if (has_mbyte && !keycode) { - dlen += (unsigned int)(*mb_char2bytes)(key, dst + dlen); + dlen += (unsigned int)utf_char2bytes(key, dst + dlen); } else if (keycode) { char_u *after = add_char2buf(key, dst + dlen); assert(after >= dst && (uintmax_t)(after - dst) <= UINT_MAX); |