The TouchEvent class is the event generated for each touch action on a multi-touch device. More...
#include <hps.h>


Public Types | |
| enum | Action : uint32_t { Action::TouchDown, Action::TouchUp, Action::Move } |
| Enumeration of various actions touches can undergo for a TouchEvent. More... | |
| enum | Status : uint32_t { Status::InProgress, Status::Completed, Status::Failed } |
| Event Status - returned from a notifier to give the status of the event. More... | |
Public Member Functions | |
| TouchEvent () | |
| The default constructor creates an uninitialized TouchEvent object. More... | |
| TouchEvent (Action in_action, ModifierKeys in_modifier=ModifierKeys()) | |
| This constructor creates a TouchEvent object for a given action without an array of Touches. More... | |
| TouchEvent (Action in_action, TouchArray const &in_touches, ModifierKeys in_modifier=ModifierKeys()) | |
| This constructor creates a TouchEvent object for a given action with an array of Touches. More... | |
| TouchEvent (Action in_action, size_t in_touch_count, Touch const in_touches[], ModifierKeys in_modifier=ModifierKeys()) | |
| This constructor creates a TouchEvent object for a given action with an array of Touches. More... | |
| TouchEvent (Event const &in_event) | |
| This constructor converts an Event Object to a TouchEvent object. More... | |
| ~TouchEvent () | |
| Event * | Clone () const |
| Allocates and returns a copy of this TouchEvent. More... | |
| virtual bool | Equals (InputEvent const &in_that) const |
| Check if the source object is equivalent to this object. More... | |
| bool | Equals (TouchEvent const &in_that) const |
| Check if the source object is equivalent to this object. More... | |
| virtual bool | operator== (TouchEvent const &in_that) const |
| Check if the source object is equivalent to this object. More... | |
| virtual bool | operator!= (TouchEvent const &in_that) const |
| Check if the source object is not equivalent to this object. More... | |
| virtual bool | Drop (Event const *in_that_event) const |
| Determines if this TouchEvent can be dropped in favor of the following touch event. More... | |
| virtual bool | operator== (InputEvent const &in_that) const |
| Check if the source object is equivalent to this object. More... | |
| virtual bool | operator!= (InputEvent const &in_that) const |
| Check if the source object is not equivalent to this object. More... | |
| ModifierKeys | GetModifierKeys () const |
| Queries which modifier keys are active. More... | |
| intptr_t | GetClassID () const |
| Returns a unique identifier that is shared by all objects of the same class. More... | |
| virtual intptr_t | Freshen () const |
| This optional function is used to determine if the current event can be dropped in favor of newer event of the same type if one is available. More... | |
| intptr_t | GetChannel () const |
| Returns the channel ID assigned to an event. More... | |
| Time | GetTimeStamp () const |
| Returns the time an event was injected into the event queue. More... | |
| bool | IsConsumable () const |
| Indicates whether an event will be consumed when it is handled or passed on to the next handler anyway. More... | |
Static Public Member Functions | |
| static void * | operator new (size_t in_size) |
| static void | operator delete (void *in_ptr, size_t in_size) throw () |
Public Attributes | |
| HPS::TouchEvent::Action | CurrentAction |
| The action for the touches of this TouchEvent. More... | |
| HPS::TouchArray | Touches |
| Array of Touches for this TouchEvent. More... | |
| ModifierKeys | ModifierKeyState |
| The modifier keys which are active for this InputEvent. More... | |
Protected Attributes | |
| intptr_t | channel |
| bool | consumable |
Static Private Member Functions | |
| static bool | sort_predicate (Touch const &in_a, Touch const &in_b) |
| Private method used for sorting Touch objects. More... | |
The TouchEvent class is the event generated for each touch action on a multi-touch device.
|
strong |
Enumeration of various actions touches can undergo for a TouchEvent.
| Enumerator | |
|---|---|
| TouchDown | A touch, or touches, has just gone down. |
| TouchUp | A touch, or touches, has just gone up. |
| Move | A touch, or touches, has just moved. |
|
stronginherited |
|
inline |
The default constructor creates an uninitialized TouchEvent object.
|
inline |
This constructor creates a TouchEvent object for a given action without an array of Touches.
Specifying TouchUp without an array of Touches clears tracked touches.
| in_action | Action of this TouchEvent. |
| in_modifier | The modifier keys for this TouchEvent. |
|
inline |
This constructor creates a TouchEvent object for a given action with an array of Touches.
Specifying TouchUp with an empty an array of Touches clears tracked touches.
| in_action | Action of this TouchEvent. |
| in_touches | An array or touches for this TouchEvent. |
| in_modifier | The modifier keys for this TouchEvent. |
|
inline |
This constructor creates a TouchEvent object for a given action with an array of Touches.
Specifying TouchUp with an empty an array of Touches clears tracked touches.
| in_action | Action of this TouchEvent. |
| in_touch_count | the number of Touches in the touch array. |
| in_touches | An array or touches for this TouchEvent. |
| in_modifier | The modifier keys for this TouchEvent. |
|
inline |
This constructor converts an Event Object to a TouchEvent object.

| HPS::TouchEvent::~TouchEvent | ( | ) |
|
inlinevirtual |
Allocates and returns a copy of this TouchEvent.
Reimplemented from HPS::InputEvent.
|
inlinevirtual |
Determines if this TouchEvent can be dropped in favor of the following touch event.
| in_that_event | Event to compare with this TouchEvent. |
Reimplemented from HPS::Event.
|
inlinevirtual |
Check if the source object is equivalent to this object.
| in_kit | The source object to compare to this object. |
Reimplemented from HPS::InputEvent.

|
inline |
Check if the source object is equivalent to this object.
| in_that | The source object to compare to this object. |

|
inlinevirtualinherited |
This optional function is used to determine if the current event can be dropped in favor of newer event of the same type if one is available.
Reimplemented in HPS::MouseEvent, HPS::TimerTickEvent, and HPS::CameraChangedEvent.
|
inlineinherited |
Returns the channel ID assigned to an event.

|
inherited |
Returns a unique identifier that is shared by all objects of the same class.

|
inlineinherited |
Queries which modifier keys are active.
|
inlineinherited |
Returns the time an event was injected into the event queue.
|
inlineinherited |
Indicates whether an event will be consumed when it is handled or passed on to the next handler anyway.
|
inlinestaticinherited | ||||||||||||||||||||

|
inlinestaticinherited |

|
inlinevirtualinherited |
Check if the source object is not equivalent to this object.
| in_that | The source object to compare to this object. |
|
inlinevirtual |
Check if the source object is not equivalent to this object.
| in_kit | The source object to compare to this object. |
|
inlinevirtualinherited |
Check if the source object is equivalent to this object.
| in_that | The source object to compare to this object. |
|
inlinevirtual |
Check if the source object is equivalent to this object.
| in_kit | The source object to compare to this object. |
|
protectedinherited |
|
protectedinherited |
| HPS::TouchEvent::Action HPS::TouchEvent::CurrentAction |
The action for the touches of this TouchEvent.
|
inherited |
The modifier keys which are active for this InputEvent.
| HPS::TouchArray HPS::TouchEvent::Touches |
Array of Touches for this TouchEvent.