cohtml.InputSystem.TouchEvent

A class storing touch input event data.

Inherits from cohtml.InputSystem.PointerEvent, ITouchEventData, cohtml.InputSystem.InputEvent, cohtml.InputSystem.IViewSendable

Public Functions

Name
TouchEvent(uint id)
Creates a touch event with the given id.
voidUpdateActiveState()
Updates the IsActive state of the event.
TouchEventDataSetNativePosition(Vector2Int position)
Sets the X and Y coordinate of the events position.

Public Properties

Name
uintId
The identification number of the event.
boolIsActive
Returns true if the touch event is active.
override EventTypePointerEventType
Returns the pointer event type.
TouchEventData.EventTypeType
The event type of this mouse event.
EventModifiersStateModifiers
The key modifiers of this touch event.

Additional inherited members

Public Types inherited from cohtml.InputSystem.PointerEvent

Name
enum classEventType { Up, Down, Move}
The type of the pointer event.

Public Functions inherited from cohtml.InputSystem.PointerEvent

Name
voidAddView(CohtmlView view, Vector2Int position)
Temporarily stores the CohtmlView component and the position where the event happened.
Vector2IntGetViewPosition(CohtmlView view)
Returns the position of the event that hit a CohtmlView.
voidRemoveView(CohtmlView view)
Removes the CohtmlView from the temporary collection of events that happened.
voidClearViews()
Clears the collection of CohtmlView components hit by this event.

Public Properties inherited from cohtml.InputSystem.PointerEvent

Name
Vector2IntPosition
The position of the pointer event.
intX
The X coordinate of the events position.
intY
The Y coordinate of the events position.

Public Functions inherited from cohtml.InputSystem.InputEvent

Name
virtual voidSend(CohtmlView view)
Sends the input event to a CohtmlView component.
voidDispose()

Public Functions inherited from cohtml.InputSystem.IViewSendable

Name
voidSend(CohtmlView view)

Public Functions Documentation

function TouchEvent

TouchEvent(
    uint id
)

Creates a touch event with the given id.

Parameters:

  • id The identification of the event.

function UpdateActiveState

void UpdateActiveState()

Updates the IsActive state of the event.

function SetNativePosition

TouchEventData SetNativePosition(
    Vector2Int position
)

Sets the X and Y coordinate of the events position.

Parameters:

  • position The event position in screen space coordinates.

Public Property Documentation

property Id

uint Id;

The identification number of the event.

property IsActive

bool IsActive;

Returns true if the touch event is active.

property PointerEventType

override EventType PointerEventType;

Returns the pointer event type.

property Type

TouchEventData.EventType Type;

The event type of this mouse event.

property Modifiers

EventModifiersState Modifiers;

The key modifiers of this touch event.