sdlButton function
/const SDLK_AUDIONEXT = SDL_SCANCODE_AUDIONEXT | SDLK_SCANCODE_MASK; /const SDLK_AUDIOPREV = SDL_SCANCODE_AUDIOPREV | SDLK_SCANCODE_MASK; /const SDLK_AUDIOSTOP = SDL_SCANCODE_AUDIOSTOP | SDLK_SCANCODE_MASK; /const SDLK_AUDIOPLAY = SDL_SCANCODE_AUDIOPLAY | SDLK_SCANCODE_MASK; /const SDLK_AUDIOMUTE = SDL_SCANCODE_AUDIOMUTE | SDLK_SCANCODE_MASK; /const SDLK_MEDIASELECT = SDL_SCANCODE_MEDIASELECT | SDLK_SCANCODE_MASK; /const SDLK_WWW = SDL_SCANCODE_WWW | SDLK_SCANCODE_MASK; /const SDLK_MAIL = SDL_SCANCODE_MAIL | SDLK_SCANCODE_MASK; /const SDLK_CALCULATOR = SDL_SCANCODE_CALCULATOR | SDLK_SCANCODE_MASK; /const SDLK_COMPUTER = SDL_SCANCODE_COMPUTER | SDLK_SCANCODE_MASK;
const SDL_BUTTON = (X) (1 << ((X)-1));
Implementation
//const SDLK_AC_SEARCH = SDL_SCANCODE_AC_SEARCH | SDLK_SCANCODE_MASK;
//const SDLK_AC_HOME = SDL_SCANCODE_AC_HOME | SDLK_SCANCODE_MASK;
//const SDLK_AC_BACK = SDL_SCANCODE_AC_BACK | SDLK_SCANCODE_MASK;
//const SDLK_AC_FORWARD = SDL_SCANCODE_AC_FORWARD | SDLK_SCANCODE_MASK;
//const SDLK_AC_STOP = SDL_SCANCODE_AC_STOP | SDLK_SCANCODE_MASK;
//const SDLK_AC_REFRESH = SDL_SCANCODE_AC_REFRESH | SDLK_SCANCODE_MASK;
//const SDLK_AC_BOOKMARKS = SDL_SCANCODE_AC_BOOKMARKS | SDLK_SCANCODE_MASK;
//const SDLK_BRIGHTNESSDOWN = SDL_SCANCODE_BRIGHTNESSDOWN | SDLK_SCANCODE_MASK;
//const SDLK_BRIGHTNESSUP = SDL_SCANCODE_BRIGHTNESSUP | SDLK_SCANCODE_MASK;
//const SDLK_DISPLAYSWITCH = SDL_SCANCODE_DISPLAYSWITCH | SDLK_SCANCODE_MASK;
//const SDLK_KBDILLUMTOGGLE = SDL_SCANCODE_KBDILLUMTOGGLE | SDLK_SCANCODE_MASK;
//const SDLK_KBDILLUMDOWN = SDL_SCANCODE_KBDILLUMDOWN | SDLK_SCANCODE_MASK;
//const SDLK_KBDILLUMUP = SDL_SCANCODE_KBDILLUMUP | SDLK_SCANCODE_MASK;
//const SDLK_EJECT = SDL_SCANCODE_EJECT | SDLK_SCANCODE_MASK;
//const SDLK_SLEEP = SDL_SCANCODE_SLEEP | SDLK_SCANCODE_MASK;
//const main = SDL_main;
/// ```c
/// const SDL_BUTTON = (X) (1 << ((X)-1));
/// ```
int sdlButton(int x) {
return 1 << (x - 1);
}