Skip to content
Snippets Groups Projects
Commit 97447a03 authored by deuce's avatar deuce
Browse files

Correctly handle CAPS/Shift interaction (For no apparent *reason*)

parent b6aa4c32
No related branches found
No related tags found
No related merge requests found
...@@ -210,10 +210,14 @@ int win32_getchcode(WORD code, DWORD state) ...@@ -210,10 +210,14 @@ int win32_getchcode(WORD code, DWORD state)
return(keyval[i].ALT); return(keyval[i].ALT);
if(state & (RIGHT_CTRL_PRESSED|LEFT_CTRL_PRESSED)) if(state & (RIGHT_CTRL_PRESSED|LEFT_CTRL_PRESSED))
return(keyval[i].CTRL); return(keyval[i].CTRL);
if(state & (SHIFT_PRESSED)) if((state & (CAPSLOCK_ON)) && isalpha(keyval[i].Key)) {
return(keyval[i].Shift); if(!(state & (SHIFT_PRESSED))
if((state & (CAPSLOCK_ON)) && isalpha(keyval[i].Key)) return(keyval[i].Shift);
return(keyval[i].Shift); }
else {
if(state & (SHIFT_PRESSED))
return(keyval[i].Shift);
}
return(keyval[i].Key); return(keyval[i].Key);
} }
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment