Mercurial > sdl-ios-xcode
comparison src/video/wscons/SDL_wsconsevents.c @ 1379:c0a74f199ecf
Use only safe string functions
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Sun, 19 Feb 2006 23:46:34 +0000 |
parents | dc0e13e7e1ae |
children | 1736c5e2173f |
comparison
equal
deleted
inserted
replaced
1378:dc0e13e7e1ae | 1379:c0a74f199ecf |
---|---|
98 { | 98 { |
99 keysym->scancode = scancode; | 99 keysym->scancode = scancode; |
100 keysym->sym = SDLK_UNKNOWN; | 100 keysym->sym = SDLK_UNKNOWN; |
101 keysym->mod = KMOD_NONE; | 101 keysym->mod = KMOD_NONE; |
102 | 102 |
103 if (scancode < SDL_TABLESIZE(keymap)) | 103 if (scancode < SDL_arraysize(keymap)) |
104 keysym->sym = keymap[scancode]; | 104 keysym->sym = keymap[scancode]; |
105 | 105 |
106 if (keysym->sym == SDLK_UNKNOWN) | 106 if (keysym->sym == SDLK_UNKNOWN) |
107 printf("Unknown mapping for scancode %d\n", scancode); | 107 printf("Unknown mapping for scancode %d\n", scancode); |
108 | 108 |
139 void WSCONS_InitOSKeymap(_THIS) | 139 void WSCONS_InitOSKeymap(_THIS) |
140 { | 140 { |
141 int i; | 141 int i; |
142 | 142 |
143 /* Make sure unknown keys are mapped correctly */ | 143 /* Make sure unknown keys are mapped correctly */ |
144 for (i=0; i < SDL_TABLESIZE(keymap); i++) { | 144 for (i=0; i < SDL_arraysize(keymap); i++) { |
145 keymap[i] = SDLK_UNKNOWN; | 145 keymap[i] = SDLK_UNKNOWN; |
146 } | 146 } |
147 | 147 |
148 switch (private->kbdType) { | 148 switch (private->kbdType) { |
149 case WSKBD_TYPE_ZAURUS: | 149 case WSKBD_TYPE_ZAURUS: |