Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
Comment: | sdl2.c: Handle C-aaaa... properly. |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | ams/sdl |
Files: | files | file ages | folders |
SHA3-256: |
8955c86dcc99e2d942ba665beb490774 |
User & Date: | ams 2024-06-25 07:36:55 |
Context
2024-06-25
| ||
08:09 | cadet.c (cadet_process_shift): Make function slightly easier to follow. check-in: 06c22160c4 user: ams tags: ams/sdl | |
07:36 | sdl2.c: Handle C-aaaa... properly. check-in: 8955c86dcc user: ams tags: ams/sdl | |
07:04 | x11.c: Minor fixes; use new API. check-in: ef2b653529 user: ams tags: ams/sdl | |
Changes
Changes to sdl2.c.
︙ | ︙ | |||
201 202 203 204 205 206 207 | shifts = 0; state = SDL_GetKeyboardState(&statesize); for (int i = 0; allup && i < statesize; i++) { int bucky; if (state[i] != 1) | | | > > > > > > > > > > > | 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 | shifts = 0; state = SDL_GetKeyboardState(&statesize); for (int i = 0; allup && i < statesize; i++) { int bucky; if (state[i] != 1) continue; /* bucky not pressed */ bucky = -1; switch (SDL_GetKeyFromScancode(i)) { case SDLK_LSHIFT: case SDLK_RSHIFT: bucky = modifier_map[ShiftMapIndex]; break; case SDLK_LCTRL: case SDLK_RCTRL: bucky = modifier_map[ControlMapIndex]; break; case SDLK_LALT: case SDLK_RALT: bucky = modifier_map[Mod1MapIndex]; break; // case SDLK_LMETA: case SDLK_RMETA: // case SDLK_LSUPER: case SDLK_RSUPER: case SDLK_MODE: bucky = modifier_map[Mod4MapIndex]; break; case SDLK_MENU: bucky = modifier_map[KBD_NoSymbol]; break; // case SDLK_COMPOSE: bucky = modifier_map[]; break; case SDLK_CAPSLOCK:bucky = modifier_map[ControlMapIndex]; break; } DEBUG(TRACE_KBD, "cadet_allup_key() - bucky pressed (%d), i = %d\n", bucky, i); cadet_press_bucky(bucky, &mods, &shifts); } if (allup == true) { DEBUG(TRACE_KBD, "cadet_allup_key() - all-up event; mods = 0%o, shifts = 0%o\n", mods, shifts); cadet_shifts = shifts; cadet_allup_event(mods); |
︙ | ︙ |