Changed operator to be more correct for utf8.

This commit is contained in:
Adam Harrison 2021-12-18 15:11:50 -05:00 committed by Guldoman
parent d237ff9c15
commit 3e7ae33597
No known key found for this signature in database
GPG Key ID: C08A498EC7F1AFDD
1 changed files with 1 additions and 1 deletions

View File

@ -109,7 +109,7 @@ static const char *get_key_name(const SDL_Event *e, char *buf) {
then we transmit it as it is. But we also need to support shortcuts in then we transmit it as it is. But we also need to support shortcuts in
other languages, so for non-Latin characters we pass the scancode that other languages, so for non-Latin characters we pass the scancode that
matches the letter in the QWERTY layout. */ matches the letter in the QWERTY layout. */
if (e->key.keysym.sym <= 128) if (e->key.keysym.sym < 128)
strcpy(buf, SDL_GetKeyName(e->key.keysym.sym)); strcpy(buf, SDL_GetKeyName(e->key.keysym.sym));
else else
strcpy(buf, SDL_GetScancodeName(scancode)); strcpy(buf, SDL_GetScancodeName(scancode));