![]() |
Public API Reference |
![]() |
Helper class to conveniently deal with joystick events. More...
#include <csutil/event.h>
Static Public Member Functions | |
static int | GetAxis (const iEvent *event, uint) |
retrieve any axis (basis 0) value | |
static uint | GetButton (const iEvent *event) |
retrieve button number | |
static uint32 | GetButtonMask (const iEvent *event) |
Retrieve current button mask. | |
static bool | GetButtonState (const iEvent *event) |
retrieve button state (pressed/released) | |
static bool | GetEventData (const iEvent *event, csJoystickEventData &data) |
Retrieve event data. | |
static void | GetModifiers (const iEvent *event, csKeyModifiers &modifiers) |
retrieve modifier flags | |
static uint32 | GetModifiers (const iEvent *event) |
Retrieve modifiers bitmask. | |
static uint | GetNumAxes (const iEvent *) |
retrieve number of axes | |
static uint | GetNumber (const iEvent *event) |
Retrieve joystick number (0, 1, 2, ...) | |
static csEvent * | NewEvent (csRef< iEventNameRegistry > ®, csTicks, csEventID name, int n, int x, int y, uint32 axesChanged, uint button, bool buttonState, uint32 buttonMask, const csKeyModifiers &modifiers) |
Create new joystick event. | |
static csEvent * | NewEvent (csRef< iEventNameRegistry > ®, csTicks, csEventID name, int n, const int32 *axes, uint8 numAxes, uint32 axesChanged, uint button, bool buttonState, uint32 buttonMask, const csKeyModifiers &modifiers) |
Create new joystick event. |
static int csJoystickEventHelper::GetAxis | ( | const iEvent * | event, |
uint | |||
) | [static] |
retrieve any axis (basis 0) value
static uint csJoystickEventHelper::GetButton | ( | const iEvent * | event | ) | [static] |
retrieve button number
static uint32 csJoystickEventHelper::GetButtonMask | ( | const iEvent * | event | ) | [static] |
Retrieve current button mask.
static bool csJoystickEventHelper::GetButtonState | ( | const iEvent * | event | ) | [static] |
retrieve button state (pressed/released)
static bool csJoystickEventHelper::GetEventData | ( | const iEvent * | event, |
csJoystickEventData & | data | ||
) | [static] |
Retrieve event data.
static void csJoystickEventHelper::GetModifiers | ( | const iEvent * | event, |
csKeyModifiers & | modifiers | ||
) | [inline, static] |
static uint32 csJoystickEventHelper::GetModifiers | ( | const iEvent * | event | ) | [inline, static] |
static uint csJoystickEventHelper::GetNumAxes | ( | const iEvent * | ) | [static] |
retrieve number of axes
static uint csJoystickEventHelper::GetNumber | ( | const iEvent * | event | ) | [static] |
Retrieve joystick number (0, 1, 2, ...)
static csEvent* csJoystickEventHelper::NewEvent | ( | csRef< iEventNameRegistry > & | reg, |
csTicks | , | ||
csEventID | name, | ||
int | n, | ||
int | x, | ||
int | y, | ||
uint32 | axesChanged, | ||
uint | button, | ||
bool | buttonState, | ||
uint32 | buttonMask, | ||
const csKeyModifiers & | modifiers | ||
) | [static] |
Create new joystick event.
static csEvent* csJoystickEventHelper::NewEvent | ( | csRef< iEventNameRegistry > & | reg, |
csTicks | , | ||
csEventID | name, | ||
int | n, | ||
const int32 * | axes, | ||
uint8 | numAxes, | ||
uint32 | axesChanged, | ||
uint | button, | ||
bool | buttonState, | ||
uint32 | buttonMask, | ||
const csKeyModifiers & | modifiers | ||
) | [static] |
Create new joystick event.