Fixed keyboard deadlock on win32
This commit is contained in:
parent
72a3864d91
commit
056c5341d9
@ -10,6 +10,8 @@ ______________________________________________________________________
|
||||
Notes for GoldED+ 1.1.5, /snapshot/
|
||||
______________________________________________________________________
|
||||
|
||||
- Fixed keyboard deadlock on win32.
|
||||
|
||||
+ Improved false quote handling.
|
||||
|
||||
! Box lines drawing keys was changed from EditGo* to EditBlock*.
|
||||
|
@ -801,7 +801,7 @@ struct kbd {
|
||||
{ VK_RETURN, Key_Ent, Key_Ent, Key_C_Ent, Key_A_Ent },
|
||||
{ VK_ESCAPE, Key_Esc, Key_Esc, Key_Esc, Key_A_Esc },
|
||||
{ VK_SPACE, -1, -1, Key_Space, Key_Space },
|
||||
{ VK_APPS, Key_S_F10, -1, -1, -1 },
|
||||
{ VK_APPS, Key_S_F10, Key_S_F10, Key_S_F10, -1 },
|
||||
|
||||
{ '0', Key_0, Key_S_0, -1, Key_A_0 },
|
||||
{ '1', Key_1, Key_S_1, -1, Key_A_1 },
|
||||
@ -933,9 +933,10 @@ int gkbd_nt2bios(INPUT_RECORD& inp) {
|
||||
c = k->alt;
|
||||
else if(state & (RIGHT_CTRL_PRESSED | LEFT_CTRL_PRESSED))
|
||||
c = k->ctrl;
|
||||
else if(state & SHIFT_PRESSED) {
|
||||
else if(state & SHIFT_PRESSED)
|
||||
{
|
||||
if (k->shift == -1)
|
||||
c = ascii;
|
||||
c = ascii ? ascii : -1;
|
||||
else
|
||||
c = k->shift;
|
||||
}
|
||||
@ -943,17 +944,19 @@ int gkbd_nt2bios(INPUT_RECORD& inp) {
|
||||
// If it is a letter key, use the ASCII value supplied
|
||||
// by NT to take into account the CapsLock state.
|
||||
if (g_isupper(keycode) or (k->normal == -1))
|
||||
c = ascii;
|
||||
c = ascii ? ascii : -1;
|
||||
else
|
||||
c = k->normal;
|
||||
}
|
||||
|
||||
if (c != -1)
|
||||
{
|
||||
if (ascii and not (right_alt_same_as_left ? (state & (LEFT_ALT_PRESSED | RIGHT_ALT_PRESSED)) : (state & LEFT_ALT_PRESSED)))
|
||||
if (isalnum(keycode))
|
||||
return (ascii == ' ') ? Key_Space : ascii;
|
||||
if (ISEXT(c))
|
||||
return EXTVAL(c) << 8;
|
||||
}
|
||||
|
||||
return c;
|
||||
}
|
||||
|
Reference in New Issue
Block a user