1SDL_JoyButtonEvent(3)          SDL API Reference         SDL_JoyButtonEvent(3)
2
3
4

NAME

6       SDL_JoyButtonEvent - Joystick button event structure
7

STRUCTURE DEFINITION

9       typedef struct{
10         Uint8 type;
11         Uint8 which;
12         Uint8 button;
13         Uint8 state;
14       } SDL_JoyButtonEvent;
15

STRUCTURE DATA

17       type                SDL_JOYBUTTONDOWN or SDL_JOYBUTTONUP
18
19       which               Joystick device index
20
21       button              Joystick button index
22
23       state               SDL_PRESSED or SDL_RELEASED
24

DESCRIPTION

26       SDL_JoyButtonEvent  is a member of the SDL_Event union and is used when
27       an event of type SDL_JOYBUTTONDOWN or SDL_JOYBUTTONUP is reported.
28
29       A SDL_JOYBUTTONDOWN or SDL_JOYBUTTONUP event occurs when  ever  a  user
30       presses  or  releases  a  button  on a joystick. The field which is the
31       index of the joystick that reported the event and button is  the  index
32       of  the  button (for a more detailed explaination see the Joystick sec‐
33       tion). state is the  current  state  or  the  button  which  is  either
34       SDL_PRESSED or SDL_RELEASED.
35

SEE ALSO

37       SDL_Event, Joystick Functions, SDL_JoystickEventState, SDL_JoystickGet‐
38       Button
39
40
41
42SDL                         Tue 11 Sep 2001, 22:59       SDL_JoyButtonEvent(3)
Impressum