Skip to main content

UIActions

ZepetoInputControl.UIActions

Handles various UI-related input actions.

Hierarchy

Constructors

constructor

new UIActions($wrapper)

Parameters

NameType
$wrapperZepetoInputControl

Overrides

System.ValueType.constructor

Accessors

Cancel

get Cancel(): InputAction

This action corresponds to a cancellation or 'back' command, allowing users to return to a previous menu or close a current UI window.

Returns

InputAction


Click

get Click(): InputAction

Represents the action of clicking a UI element, akin to mouse clicks or screen taps.

Returns

InputAction


MiddleClick

get MiddleClick(): InputAction

Represents the action of pressing the middle mouse button.

Returns

InputAction


get Navigate(): InputAction

This action handles navigation through UI elements, such as menus or lists, typically using directional inputs like arrow keys, joystick movement, or swipe gestures.

Returns

InputAction


Point

get Point(): InputAction

Handles the pointing mechanism in UI, similar to moving a mouse cursor or a finger touch point on touchscreens.

Returns

InputAction


RightClick

get RightClick(): InputAction

Corresponds to the action of right-clicking with a mouse, often used to open context menus or perform secondary actions.

Returns

InputAction


ScrollWheel

get ScrollWheel(): InputAction

This action is used to capture scrolling input, such as from a mouse wheel or a touchpad gesture.

Returns

InputAction


Submit

get Submit(): InputAction

Represents the action of confirming or selecting a highlighted UI element, equivalent to a 'Enter' or 'OK' command.

Returns

InputAction


TrackedDeviceOrientation

get TrackedDeviceOrientation(): InputAction

Tracks the orientation of a device, typically used in VR or AR setups to detect the direction in which a device is pointed or facing.

Returns

InputAction


TrackedDevicePosition

get TrackedDevicePosition(): InputAction

Captures the positional data of a tracked device, like a VR controller or a motion tracking device.

Returns

InputAction


enabled

get enabled(): boolean

Indicates whether the UI actions are currently active and responsive to input.

Returns

boolean

Methods

Disable

Disable(): void

Deactivates the UI input actions, rendering them unresponsive to user input.

Returns

void


Enable

Enable(): void

Activates the UI input actions, making them responsive to user input.

Returns

void


Get

Get(): InputActionMap

Returns the InputActionMap associated with UI actions.

Returns

InputActionMap

The returned InputActionMap includes all the input actions defined for UI interactions within the ZepetoInputControl class.


SetCallbacks

SetCallbacks($instance): void

Registers callback methods for the UI actions. It links the actions to their respective event handlers as defined in the IUIActions interface implemented by the instance.

Parameters

NameTypeDescription
$instanceIUIActionsAn object that implements the IUIActions interface.

Returns

void