KSD_EXPORT_CLASSclass TEventDispatcher

Passes events down the widget tree.

Public Methods

[more] TEventDispatcher(TWidgetTree* _tree)
Contruct an event dispatcher that uses the given widget tree
[more]TWidgetTree* GetWidgetTree()
Returns the widget tree that this object dispatches to
[more]bool GetJoystickAxisRepeat() const
Returns true if joystick axis repeat is enabled
[more]bool GetJoystickEvents() const
Returns true if joystick events are enabled
[more]bool GetJoystickCursor() const
Returns true if joystick cursor is enabled
[more]unsigned int GetJoystickCursorSensitivity() const
Returns the joystick cursor sensitivity
[more]unsigned int GetJoystickCursorNum() const
Returns the joystick number that controls the cursor
[more]TWidget* GetKeyboardFocus()
Returns the widget receiving keyboard focus
[more]TWidget* GetMouseFocus()
Returns the widget receiving mouse input
[more]TWidget* GetJoystickFocus()
Returns the widget receiving joystick input
[more]void SetJoystickAxisRepeat(bool enable)
Enables/disables joystick axis repeat.
[more]void SetJoystickEvents(bool enable)
Enables/disables joystick events.
[more]void SetJoystickCursor(bool enable)
Enables/disables the joystick cursor.
[more]void SetJoystickCursorSensitvity(unsigned int _s)
Sets the joystick cursor sensitivity
[more]void SetJoystickCursorNum(unsigned int _joy)
Sets which joystick controls the cursor
[more]void SetKeyboardFocus(TWidget* w)
Sets the widget to recieve keyboard input
[more]void SetJoystickFocus(TWidget* w)
Sets the widget to receive joystick input
[more]void HandleMouseDown(int X, int Y, TMouseButton button)
Dispatch the mouse down event to the widget tree.
[more]void HandleMouseMove(int X, int Y, int RelX, int RelY, TMouseButton button)
Dispatch the mouse move event to the widget tree.
[more]void HandleEnterRoot()
Dispatch the enter root event.
[more]void HandleExitRoot()
Dispatch the enter root event.
[more]void HandleMouseUp(int X, int Y, TMouseButton button)
Dispatch the mouse up event to the widget tree
[more]void HandleKeyDown(const TKey& key)
Dispatch the key down event to the widget tree
[more]void HandleKeyUp(const TKey& key)
Dispatch the key up event to the widget tree
[more]void HandleJoyAxisMove(Uint8 joy, Uint8 axis, Sint16 value)
Dispatch the joy axis move event to the widget tree
[more]void HandleJoyBallMove(Uint8 joy, Uint8 axis, Sint16 X, Sint16 Y)
Dispatch the joy ball move event to the widget tree
[more]void HandleJoyHatMove(Uint8 joy, Uint8 hat, TJoyHatPosition pos)
Dispatch the joy hat move event to the widget tree
[more]void HandleJoyDown(Uint8 joy, Uint8 button)
Dispatch the joy down event to the widget tree
[more]void HandleJoyUp(Uint8 joy, Uint8 button)
Dispatch the joy up event to the widget tree
[more]virtual void PollEvents() = 0
Override to provide the actual event polling and dispatching code based on the underlying event backend

Protected Methods

[more]virtual void DoSetJoystickAxisRepeat(bool enable) = 0
Override to do system specific set-up for joystick axis repeat
[more]virtual void DoSetJoystickEvents(bool enable) = 0
Override to do system specific set-up for joystick events
[more]virtual void DoSetJoystickCursor(bool enable) = 0
Override to do system specific set-up for joystick cursor
[more]virtual void DoSetJoystickCursorSensitivity(unsigned int) = 0
Override to do system specific set-up for joystick cursor sensitivity
[more]virtual void DoSetJoystickCursorNum(unsigned int) = 0
Override to do system specific set-up for joystick cursor number


Documentation

Passes events down the widget tree. Override this class to provide a new event backend.
o TEventDispatcher(TWidgetTree* _tree)
Contruct an event dispatcher that uses the given widget tree

oTWidgetTree* GetWidgetTree()
Returns the widget tree that this object dispatches to

obool GetJoystickAxisRepeat() const
Returns true if joystick axis repeat is enabled

obool GetJoystickEvents() const
Returns true if joystick events are enabled

obool GetJoystickCursor() const
Returns true if joystick cursor is enabled

ounsigned int GetJoystickCursorSensitivity() const
Returns the joystick cursor sensitivity

ounsigned int GetJoystickCursorNum() const
Returns the joystick number that controls the cursor

oTWidget* GetKeyboardFocus()
Returns the widget receiving keyboard focus

oTWidget* GetMouseFocus()
Returns the widget receiving mouse input

oTWidget* GetJoystickFocus()
Returns the widget receiving joystick input

ovoid SetJoystickAxisRepeat(bool enable)
Enables/disables joystick axis repeat. This causes all axis events to be repeated until they no longer occur.

ovoid SetJoystickEvents(bool enable)
Enables/disables joystick events. When disabled the application will not receive any joystick events.

ovoid SetJoystickCursor(bool enable)
Enables/disables the joystick cursor. This causes a particular joystick to control the cursor. (Note: As of libksd 0.0.4 this is not implemented.)

ovoid SetJoystickCursorSensitvity(unsigned int _s)
Sets the joystick cursor sensitivity

ovoid SetJoystickCursorNum(unsigned int _joy)
Sets which joystick controls the cursor

ovoid SetKeyboardFocus(TWidget* w)
Sets the widget to recieve keyboard input

ovoid SetJoystickFocus(TWidget* w)
Sets the widget to receive joystick input

ovoid HandleMouseDown(int X, int Y, TMouseButton button)
Dispatch the mouse down event to the widget tree. The clicked widget receives the mouse focus.

ovoid HandleMouseMove(int X, int Y, int RelX, int RelY, TMouseButton button)
Dispatch the mouse move event to the widget tree. This will also deal with calling the OnEnter and OnExit handlers when appropriate.

ovoid HandleEnterRoot()
Dispatch the enter root event. This event occurs when the mouse enters the root widget (usually the window in which libksd resides, but this depends on the backend).

ovoid HandleExitRoot()
Dispatch the enter root event. This event occurs when the mouse exits the root widget (usually the window in which libksd resides, but this depends on the backend).

ovoid HandleMouseUp(int X, int Y, TMouseButton button)
Dispatch the mouse up event to the widget tree

ovoid HandleKeyDown(const TKey& key)
Dispatch the key down event to the widget tree

ovoid HandleKeyUp(const TKey& key)
Dispatch the key up event to the widget tree

ovoid HandleJoyAxisMove(Uint8 joy, Uint8 axis, Sint16 value)
Dispatch the joy axis move event to the widget tree

ovoid HandleJoyBallMove(Uint8 joy, Uint8 axis, Sint16 X, Sint16 Y)
Dispatch the joy ball move event to the widget tree

ovoid HandleJoyHatMove(Uint8 joy, Uint8 hat, TJoyHatPosition pos)
Dispatch the joy hat move event to the widget tree

ovoid HandleJoyDown(Uint8 joy, Uint8 button)
Dispatch the joy down event to the widget tree

ovoid HandleJoyUp(Uint8 joy, Uint8 button)
Dispatch the joy up event to the widget tree

ovirtual void PollEvents() = 0
Override to provide the actual event polling and dispatching code based on the underlying event backend

ovirtual void DoSetJoystickAxisRepeat(bool enable) = 0
Override to do system specific set-up for joystick axis repeat

ovirtual void DoSetJoystickEvents(bool enable) = 0
Override to do system specific set-up for joystick events

ovirtual void DoSetJoystickCursor(bool enable) = 0
Override to do system specific set-up for joystick cursor

ovirtual void DoSetJoystickCursorSensitivity(unsigned int) = 0
Override to do system specific set-up for joystick cursor sensitivity

ovirtual void DoSetJoystickCursorNum(unsigned int) = 0
Override to do system specific set-up for joystick cursor number


This class has no child classes.

Alphabetic index HTML hierarchy of classes or Java



This page was generated with the help of DOC++.