Skip to content

Commit

Permalink
*** empty log message ***
Browse files Browse the repository at this point in the history
  • Loading branch information
slouken committed Mar 31, 2002
1 parent 1e43a94 commit b647fb0
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 10 deletions.
3 changes: 3 additions & 0 deletions src/video/wincommon/SDL_sysevents.c
Expand Up @@ -131,6 +131,7 @@ static void WIN_GetKeyboardState(void)
#ifndef NO_GETKEYBOARDSTATE
SDLMod state;
BYTE keyboard[256];
Uint8 *kstate = SDL_GetKeyState(NULL);

state = KMOD_NONE;
if ( GetKeyboardState(keyboard) ) {
Expand All @@ -154,9 +155,11 @@ static void WIN_GetKeyboardState(void)
}
if ( keyboard[VK_NUMLOCK] & 0x01) {
state |= KMOD_NUM;
kstate[SDLK_NUMLOCK] = SDL_PRESSED;
}
if ( keyboard[VK_CAPITAL] & 0x01) {
state |= KMOD_CAPS;
kstate[SDLK_CAPSLOCK] = SDL_PRESSED;
}
}
SDL_SetModState(state);
Expand Down
3 changes: 1 addition & 2 deletions src/video/wincommon/SDL_wingl.c
Expand Up @@ -27,8 +27,7 @@ static char rcsid =

/* WGL implementation of SDL OpenGL support */

#include <windows.h>

#include "SDL_opengl.h"
#include "SDL_error.h"
#include "SDL_lowvideo.h"
#include "SDL_wingl_c.h"
Expand Down
1 change: 1 addition & 0 deletions src/video/windib/SDL_dibevents.c
Expand Up @@ -215,6 +215,7 @@ void DIB_InitOSKeymap(_THIS)
VK_keymap[VK_BACKSLASH] = SDLK_BACKSLASH;
VK_keymap[VK_RBRACKET] = SDLK_RIGHTBRACKET;
VK_keymap[VK_GRAVE] = SDLK_BACKQUOTE;
VK_keymap[VK_BACKTICK] = SDLK_BACKQUOTE;
VK_keymap[VK_A] = SDLK_a;
VK_keymap[VK_B] = SDLK_b;
VK_keymap[VK_C] = SDLK_c;
Expand Down
17 changes: 9 additions & 8 deletions src/video/windib/SDL_vkeys.h
Expand Up @@ -66,13 +66,14 @@ static char rcsid =

/* These keys haven't been defined, but were experimentally determined */
#define VK_SEMICOLON 0xBA
#define VK_EQUALS 0xBB
#define VK_COMMA 0xBC
#define VK_MINUS 0xBD
#define VK_PERIOD 0xBE
#define VK_SLASH 0xBF
#define VK_GRAVE 0xC0
#define VK_LBRACKET 0xDB
#define VK_EQUALS 0xBB
#define VK_COMMA 0xBC
#define VK_MINUS 0xBD
#define VK_PERIOD 0xBE
#define VK_SLASH 0xBF
#define VK_GRAVE 0xC0
#define VK_LBRACKET 0xDB
#define VK_BACKSLASH 0xDC
#define VK_RBRACKET 0xDD
#define VK_RBRACKET 0xDD
#define VK_APOSTROPHE 0xDE
#define VK_BACKTICK 0xDF
4 changes: 4 additions & 0 deletions src/video/windx5/SDL_dx5events.c
Expand Up @@ -624,6 +624,9 @@ void DX5_InitOSKeymap(_THIS)
{
#ifndef DIK_PAUSE
#define DIK_PAUSE 0xC5
#endif
#ifndef DIK_OEM_102
#define DIK_OEM_102 0x56 /* < > | on UK/Germany keyboards */
#endif
int i;

Expand Down Expand Up @@ -675,6 +678,7 @@ void DX5_InitOSKeymap(_THIS)
DIK_keymap[DIK_GRAVE] = SDLK_BACKQUOTE;
DIK_keymap[DIK_LSHIFT] = SDLK_LSHIFT;
DIK_keymap[DIK_BACKSLASH] = SDLK_BACKSLASH;
DIK_keymap[DIK_OEM_102] = SDLK_BACKSLASH;
DIK_keymap[DIK_Z] = SDLK_z;
DIK_keymap[DIK_X] = SDLK_x;
DIK_keymap[DIK_C] = SDLK_c;
Expand Down

0 comments on commit b647fb0

Please sign in to comment.