mirror of
https://git.do.srb2.org/KartKrew/Kart-Public.git
synced 2024-12-29 13:51:24 +00:00
Merge branch 'fix-clang-compile' into 'master'
Fix clang compiling See merge request KartKrew/Kart-Public!176
This commit is contained in:
commit
e229aabf22
1 changed files with 1 additions and 30 deletions
29
src/d_main.c
29
src/d_main.c
|
@ -187,35 +187,6 @@ UINT8 shiftdown = 0; // 0x1 left, 0x2 right
|
||||||
UINT8 ctrldown = 0; // 0x1 left, 0x2 right
|
UINT8 ctrldown = 0; // 0x1 left, 0x2 right
|
||||||
UINT8 altdown = 0; // 0x1 left, 0x2 right
|
UINT8 altdown = 0; // 0x1 left, 0x2 right
|
||||||
boolean capslock = 0; // gee i wonder what this does.
|
boolean capslock = 0; // gee i wonder what this does.
|
||||||
//
|
|
||||||
// D_ModifierKeyResponder
|
|
||||||
// Sets global shift/ctrl/alt variables, never actually eats events
|
|
||||||
//
|
|
||||||
static inline void D_ModifierKeyResponder(event_t *ev)
|
|
||||||
{
|
|
||||||
if (ev->type == ev_keydown || ev->type == ev_console) switch (ev->data1)
|
|
||||||
{
|
|
||||||
case KEY_LSHIFT: shiftdown |= 0x1; return;
|
|
||||||
case KEY_RSHIFT: shiftdown |= 0x2; return;
|
|
||||||
case KEY_LCTRL: ctrldown |= 0x1; return;
|
|
||||||
case KEY_RCTRL: ctrldown |= 0x2; return;
|
|
||||||
case KEY_LALT: altdown |= 0x1; return;
|
|
||||||
case KEY_RALT: altdown |= 0x2; return;
|
|
||||||
case KEY_CAPSLOCK: capslock = !capslock; return;
|
|
||||||
|
|
||||||
default: return;
|
|
||||||
}
|
|
||||||
else if (ev->type == ev_keyup) switch (ev->data1)
|
|
||||||
{
|
|
||||||
case KEY_LSHIFT: shiftdown &= ~0x1; return;
|
|
||||||
case KEY_RSHIFT: shiftdown &= ~0x2; return;
|
|
||||||
case KEY_LCTRL: ctrldown &= ~0x1; return;
|
|
||||||
case KEY_RCTRL: ctrldown &= ~0x2; return;
|
|
||||||
case KEY_LALT: altdown &= ~0x1; return;
|
|
||||||
case KEY_RALT: altdown &= ~0x2; return;
|
|
||||||
default: return;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
//
|
//
|
||||||
// D_ProcessEvents
|
// D_ProcessEvents
|
||||||
|
|
Loading…
Reference in a new issue