mirror of
https://github.com/vim/vim.git
synced 2025-09-25 03:54:15 -04:00
patch 8.1.1269: MS-Windows GUI: multibyte chars with a 0x80 byte do not work
Problem: MS-Windows GUI: multibyte chars with a 0x80 byte do not work when compiled with VIMDLL. Solution: Adjust the condition for fixing the input buffer. (Ken Takata, closes #4330)
This commit is contained in:
@@ -3095,7 +3095,7 @@ inchar(
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
* Fix typed characters for use by vgetc() and check_termcode().
|
* Fix typed characters for use by vgetc() and check_termcode().
|
||||||
* buf[] must have room to triple the number of bytes!
|
* "buf[]" must have room to triple the number of bytes!
|
||||||
* Returns the new length.
|
* Returns the new length.
|
||||||
*/
|
*/
|
||||||
int
|
int
|
||||||
@@ -3135,14 +3135,15 @@ fix_input_buffer(char_u *buf, int len)
|
|||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
if (p[0] == NUL || (p[0] == K_SPECIAL
|
if (p[0] == NUL || (p[0] == K_SPECIAL
|
||||||
/* timeout may generate K_CURSORHOLD */
|
// timeout may generate K_CURSORHOLD
|
||||||
&& (i < 2 || p[1] != KS_EXTRA || p[2] != (int)KE_CURSORHOLD)
|
&& (i < 2 || p[1] != KS_EXTRA || p[2] != (int)KE_CURSORHOLD)
|
||||||
#if defined(MSWIN) && (!defined(FEAT_GUI) || defined(VIMDLL))
|
#if defined(MSWIN) && (!defined(FEAT_GUI) || defined(VIMDLL))
|
||||||
|
// Win32 console passes modifiers
|
||||||
|
&& (
|
||||||
# ifdef VIMDLL
|
# ifdef VIMDLL
|
||||||
&& !gui.in_use
|
gui.in_use ||
|
||||||
# endif
|
# endif
|
||||||
/* Win32 console passes modifiers */
|
(i < 2 || p[1] != KS_MODIFIER))
|
||||||
&& (i < 2 || p[1] != KS_MODIFIER)
|
|
||||||
#endif
|
#endif
|
||||||
))
|
))
|
||||||
{
|
{
|
||||||
@@ -3154,7 +3155,7 @@ fix_input_buffer(char_u *buf, int len)
|
|||||||
len += 2;
|
len += 2;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
*p = NUL; /* add trailing NUL */
|
*p = NUL; // add trailing NUL
|
||||||
return len;
|
return len;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -767,6 +767,8 @@ static char *(features[]) =
|
|||||||
|
|
||||||
static int included_patches[] =
|
static int included_patches[] =
|
||||||
{ /* Add new patch number below this line */
|
{ /* Add new patch number below this line */
|
||||||
|
/**/
|
||||||
|
1269,
|
||||||
/**/
|
/**/
|
||||||
1268,
|
1268,
|
||||||
/**/
|
/**/
|
||||||
|
Reference in New Issue
Block a user