ClickEvent
A click event. The semantics of this event is slightly depending on hardware platform. ClickEvents are generated by the HAL layer.
See: Event
Inherits from: Event
Public Types
enum | ClickEventType { PRESSED, RELEASED, CANCEL } |
Values that represent click event types. | |
Public Functions
ClickEvent(ClickEventType type, int16_t x, int16_t y, int16_t force =0) | |
Initializes a new instance of the ClickEvent class. | |
virtual Event::EventType | getEventType() const |
Gets event type. | |
int16_t | getForce() const |
Gets the force of the click. | |
ClickEventType | getType() const |
Gets the click type of this event. | |
int16_t | getX() const |
Gets the x coordinate of this event. | |
int16_t | getY() const |
Gets the y coordinate of this event. | |
void | setType(ClickEventType type) |
Sets the click type of this event. | |
void | setX(int16_t x) |
Sets the x coordinate of this event. | |
void | setY(int16_t y) |
Sets the y coordinate of this event. | |
Additional inherited members
Public Types inherited from Event
enum | EventType { EVENT_CLICK, EVENT_DRAG, EVENT_GESTURE } |
The event types. | |
Public Functions inherited from Event
Public Types Documentation
ClickEventType
enum ClickEventType
Values that represent click event types.
PRESSED | An enum constant representing the pressed option. |
RELEASED | An enum constant representing the released option. |
CANCEL | An enum constant representing the cancel option. |
Public Functions Documentation
ClickEvent
ClickEvent | ( | ClickEventType | type , | ||
int16_t | x , | ||||
int16_t | y , | ||||
int16_t | force =0 | ||||
) |
Initializes a new instance of the ClickEvent class.
type | The type of the click event. |
x | The x coordinate of the click event. |
y | The y coordinate of the click event. |
force | (Optional) The force of the click. On touch displays this usually means how hard the user pressed on the display. On the windows platform, this will always be zero. |
getEventType
virtual Event::EventType getEventType | ( | ) | const |
getForce
int16_t getForce | ( | ) | const |
Gets the force of the click.
On touch displays this usually means how hard the user pressed on the display. On the windows platform, this will always be zero.
The force of the click.
getType
ClickEventType getType | ( | ) | const |
Gets the click type of this event.
The click type of this event.
getX
int16_t getX | ( | ) | const |
Gets the x coordinate of this event.
The x coordinate of this event.
getY
int16_t getY | ( | ) | const |
Gets the y coordinate of this event.
The y coordinate of this event.
setType
void setType | ( | ClickEventType | type | ) | |
Sets the click type of this event.
type | The type to set. |
setX
void setX | ( | int16_t | x | ) | |
Sets the x coordinate of this event.
x | The x coordinate of this event. |
setY
void setY | ( | int16_t | y | ) | |
Sets the y coordinate of this event.
y | The y coordinate of this event. |