Mercurial > vim
comparison src/getchar.c @ 27736:ef89db30e46c v8.2.4394
patch 8.2.4394: UTF8 select mode test fails on MS-Windows
Commit: https://github.com/vim/vim/commit/9fdde7992ab4c21517f447ca3d651b9ff4a770e8
Author: Bram Moolenaar <Bram@vim.org>
Date: Tue Feb 15 19:52:56 2022 +0000
patch 8.2.4394: UTF8 select mode test fails on MS-Windows
Problem: UTF8 select mode test fails on MS-Windows.
Solution: Revert the #ifdef change.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Tue, 15 Feb 2022 21:00:03 +0100 |
parents | 4cc78957f550 |
children | 49b667252942 |
comparison
equal
deleted
inserted
replaced
27735:59ddc5d85787 | 27736:ef89db30e46c |
---|---|
3669 if (gui.in_use && p[0] == CSI && i >= 2) | 3669 if (gui.in_use && p[0] == CSI && i >= 2) |
3670 { | 3670 { |
3671 p += 2; | 3671 p += 2; |
3672 i -= 2; | 3672 i -= 2; |
3673 } | 3673 } |
3674 # ifndef MSWIN | 3674 // When the GUI is not used CSI needs to be escaped. |
3675 // When not on MS-Windows and the GUI is not used CSI needs to be | |
3676 // escaped. | |
3677 else if (!gui.in_use && p[0] == CSI) | 3675 else if (!gui.in_use && p[0] == CSI) |
3678 { | 3676 { |
3679 mch_memmove(p + 3, p + 1, (size_t)i); | 3677 mch_memmove(p + 3, p + 1, (size_t)i); |
3680 *p++ = K_SPECIAL; | 3678 *p++ = K_SPECIAL; |
3681 *p++ = KS_EXTRA; | 3679 *p++ = KS_EXTRA; |
3682 *p = (int)KE_CSI; | 3680 *p = (int)KE_CSI; |
3683 len += 2; | 3681 len += 2; |
3684 } | 3682 } |
3685 # endif | |
3686 else | 3683 else |
3687 #endif | 3684 #endif |
3688 if (p[0] == NUL || (p[0] == K_SPECIAL | 3685 if (p[0] == NUL || (p[0] == K_SPECIAL |
3689 // timeout may generate K_CURSORHOLD | 3686 // timeout may generate K_CURSORHOLD |
3690 && (i < 2 || p[1] != KS_EXTRA || p[2] != (int)KE_CURSORHOLD) | 3687 && (i < 2 || p[1] != KS_EXTRA || p[2] != (int)KE_CURSORHOLD) |