CrystalSpace

Public API Reference

csKeyEventHelper Class Reference
[Event handling]

Helper class to conveniently deal with keyboard events. More...

#include <csutil/event.h>

List of all members.

Static Public Member Functions

static bool GetAutoRepeat (const iEvent *event)
 Retrieve whether a keyboard down event was caused by the initial press (not auto-repeat) or by having it held for a period of time (auto-repeat.
static csKeyCharType GetCharacterType (const iEvent *event)
 Retrieve the character type (dead or normal.).
static utf32_char GetCookedCode (const iEvent *event)
 Retrieve the key's cooked code.
static bool GetEventData (const iEvent *event, csKeyEventData &data)
 Get all the information in one compact struct.
static csKeyEventType GetEventType (const iEvent *event)
 Retrieve the event type (key up or down.).
static void GetModifiers (uint32 mask, csKeyModifiers &modifiers)
 Convert a bitmask returned by GetModifiersBits back to a csKeyModifiers struct.
static void GetModifiers (const iEvent *event, csKeyModifiers &modifiers)
 Retrieve the key's raw code.
static uint32 GetModifiersBits (const iEvent *event)
 Get a bitmask corresponding to the pressed modifier keys from the event.
static uint32 GetModifiersBits (const csKeyModifiers &modifiers)
 Get a bitmask corresponding to the pressed modifier keys from the keyboard modifiers struct.
static utf32_char GetRawCode (const iEvent *event)
 Retrieve the key's raw code.


Detailed Description

Helper class to conveniently deal with keyboard events.

Definition at line 41 of file event.h.


Member Function Documentation

static bool csKeyEventHelper::GetAutoRepeat ( const iEvent event  )  [static]

Retrieve whether a keyboard down event was caused by the initial press (not auto-repeat) or by having it held for a period of time (auto-repeat.

)

static csKeyCharType csKeyEventHelper::GetCharacterType ( const iEvent event  )  [static]

Retrieve the character type (dead or normal.).

static utf32_char csKeyEventHelper::GetCookedCode ( const iEvent event  )  [static]

Retrieve the key's cooked code.

static bool csKeyEventHelper::GetEventData ( const iEvent event,
csKeyEventData data 
) [static]

Get all the information in one compact struct.

static csKeyEventType csKeyEventHelper::GetEventType ( const iEvent event  )  [static]

Retrieve the event type (key up or down.).

static void csKeyEventHelper::GetModifiers ( uint32  mask,
csKeyModifiers modifiers 
) [static]

Convert a bitmask returned by GetModifiersBits back to a csKeyModifiers struct.

Also works for the Modifiers members of the csMouseEventData and csJoystickEventData structs, if you cast them to uint32.

static void csKeyEventHelper::GetModifiers ( const iEvent event,
csKeyModifiers modifiers 
) [static]

Retrieve the key's raw code.

Referenced by csJoystickEventHelper::GetModifiers(), and csMouseEventHelper::GetModifiers().

static uint32 csKeyEventHelper::GetModifiersBits ( const iEvent event  )  [static]

Get a bitmask corresponding to the pressed modifier keys from the event.

See also:
CSMASK_ALT etc.

static uint32 csKeyEventHelper::GetModifiersBits ( const csKeyModifiers modifiers  )  [static]

Get a bitmask corresponding to the pressed modifier keys from the keyboard modifiers struct.

See also:
CSMASK_ALT etc.

Referenced by csJoystickEventHelper::GetModifiers(), and csMouseEventHelper::GetModifiers().

static utf32_char csKeyEventHelper::GetRawCode ( const iEvent event  )  [static]

Retrieve the key's raw code.


The documentation for this class was generated from the following file:
Generated for Crystal Space by doxygen 1.4.7