tecs.platform.events
Typed platform events produced by the Rust host.
Every kind is its own nupp.events declaration, so a world delivers a key press to the observers of KeyDown and nothing else, and the twelve shapes the kinds share are unions of the declarations that carry them. Kind strings are a stable external data surface used by recordings and tools. Rust translates winit events into these records and passes one ordered batch to tecs.application.Application:iterate.
Module contents
Types
| Type | Kind | Description |
|---|---|---|
Event | type | An event in one sealed host batch. |
FingerCanceled | record | A touch the platform cancelled. |
FingerDown | record | A finger touching the surface. |
FingerMotion | record | A finger moving on the surface. |
FingerUp | record | A finger leaving the surface. |
FocusEvent | type | A window focus transition. |
GamepadAdded | record | A gamepad appearing. |
GamepadAxis | record | A gamepad axis reading. |
GamepadAxisEvent | type | A gamepad axis reading. |
GamepadButtonDown | record | A gamepad button going down. |
GamepadButtonEvent | type | A gamepad button transition. |
GamepadButtonUp | record | A gamepad button coming up. |
GamepadDeviceEvent | type | A gamepad appearing or going away. |
GamepadRemoved | record | A gamepad going away. |
KeyDown | record | A key going down. |
KeyEvent | type | A physical and logical keyboard transition. |
KeyUp | record | A key coming up. |
Kind | type | A platform event kind supported by the Rust host. |
MouseDown | record | A pointer button going down. |
MouseMotion | record | An absolute pointer position and optional relative movement. |
MouseUp | record | A pointer button coming up. |
MouseWheel | record | A normalized pointer wheel movement. |
PointerButtonEvent | type | A pointer button transition. |
PointerMoveEvent | type | An absolute pointer position and optional relative movement. |
Quit | record | A process quit request. |
QuitEvent | type | A process or window close request. |
ResizeEvent | type | A logical window size change. |
TextEvent | type | Text committed by the platform input method. |
TextInput | record | Text committed by the platform input method. |
TouchEvent | type | One finger on a touch surface. |
WheelEvent | type | A normalized pointer wheel movement. |
WindowCloseRequested | record | A close request for one window. |
WindowFocusGained | record | A window gaining focus. |
WindowFocusLost | record | A window losing focus. |
WindowResized | record | A logical window resize. |
WindowScaleChanged | record | A scale-factor change with the resulting logical size. |
Functions
| Function | Kind | Description |
|---|---|---|
closeRequested | function | Constructs a close request for one window. |
dispatch | function | Delivers one translated event to the world's observers of its kind. |
focused | function | Constructs a window focus transition. |
gamepadAxis | function | Constructs a gamepad axis reading. |
gamepadButton | function | Constructs a gamepad button transition. |
gamepadDevice | function | Constructs a gamepad appearing or going away. |
key | function | Constructs a keyboard transition. |
kinds | function | Returns every platform event kind, in the union's declared order. |
pointerButton | function | Constructs a pointer button transition. |
pointerMoved | function | Constructs an absolute pointer movement. |
quit | function | Constructs a process or window close request. |
resized | function | Constructs a logical window resize. |
scaleChanged | function | Constructs a scale-factor change with the resulting logical size. |
text | function | Constructs committed text input. |
touch | function | Constructs one finger's transition or movement. |
wheel | function | Constructs normalized pointer wheel movement. |
Types#
Eventtype#
type Event = Quit
| WindowCloseRequested
| WindowResized
| WindowScaleChanged
| WindowFocusGained
| WindowFocusLost
| KeyDown
| KeyUp
| MouseMotion
| MouseDown
| MouseUp
| MouseWheel
| TextInput
| FingerDown
| FingerUp
| FingerMotion
| FingerCanceled
| GamepadAdded
| GamepadRemoved
| GamepadButtonDown
| GamepadButtonUp
| GamepadAxisAn event in one sealed host batch.
FingerCanceledrecord#
record FingerCanceled ...A touch the platform cancelled.
Members
| Name | Kind | Description |
|---|---|---|
kind | field | |
timestamp | field | |
sequence | field | |
window | field | |
touchDevice | field | |
finger | field | |
x | field | |
y | field | |
dx | field | |
dy | field | |
normalX | field | |
normalY | field | |
pressure | field | |
down | field |
kindfield#
kind: "fingerCanceled"timestampfield#
timestamp: numbersequencefield#
sequence: integerwindowfield#
window: integertouchDevicefield#
touchDevice: stringfingerfield#
finger: stringxfield#
x: numberyfield#
y: numberdxfield#
dx: numberdyfield#
dy: numbernormalXfield#
normalX: numbernormalYfield#
normalY: numberpressurefield#
pressure: numberdownfield#
down: booleanFingerDownrecord#
record FingerDown ...A finger touching the surface.
Members
| Name | Kind | Description |
|---|---|---|
kind | field | |
timestamp | field | |
sequence | field | |
window | field | |
touchDevice | field | |
finger | field | |
x | field | |
y | field | |
dx | field | |
dy | field | |
normalX | field | |
normalY | field | |
pressure | field | |
down | field |
kindfield#
kind: "fingerDown"timestampfield#
timestamp: numbersequencefield#
sequence: integerwindowfield#
window: integertouchDevicefield#
touchDevice: stringfingerfield#
finger: stringxfield#
x: numberyfield#
y: numberdxfield#
dx: numberdyfield#
dy: numbernormalXfield#
normalX: numbernormalYfield#
normalY: numberpressurefield#
pressure: numberdownfield#
down: booleanFingerMotionrecord#
record FingerMotion ...A finger moving on the surface.
Members
| Name | Kind | Description |
|---|---|---|
kind | field | |
timestamp | field | |
sequence | field | |
window | field | |
touchDevice | field | |
finger | field | |
x | field | |
y | field | |
dx | field | |
dy | field | |
normalX | field | |
normalY | field | |
pressure | field | |
down | field |
kindfield#
kind: "fingerMotion"timestampfield#
timestamp: numbersequencefield#
sequence: integerwindowfield#
window: integertouchDevicefield#
touchDevice: stringfingerfield#
finger: stringxfield#
x: numberyfield#
y: numberdxfield#
dx: numberdyfield#
dy: numbernormalXfield#
normalX: numbernormalYfield#
normalY: numberpressurefield#
pressure: numberdownfield#
down: booleanFingerUprecord#
record FingerUp ...A finger leaving the surface.
Members
| Name | Kind | Description |
|---|---|---|
kind | field | |
timestamp | field | |
sequence | field | |
window | field | |
touchDevice | field | |
finger | field | |
x | field | |
y | field | |
dx | field | |
dy | field | |
normalX | field | |
normalY | field | |
pressure | field | |
down | field |
kindfield#
kind: "fingerUp"timestampfield#
timestamp: numbersequencefield#
sequence: integerwindowfield#
window: integertouchDevicefield#
touchDevice: stringfingerfield#
finger: stringxfield#
x: numberyfield#
y: numberdxfield#
dx: numberdyfield#
dy: numbernormalXfield#
normalX: numbernormalYfield#
normalY: numberpressurefield#
pressure: numberdownfield#
down: booleanFocusEventtype#
type FocusEvent = WindowFocusGained | WindowFocusLostA window focus transition.
Whichever kind carries this shape; an observer written against it fits any of them.
GamepadAddedrecord#
record GamepadAdded ...A gamepad appearing.
kindfield#
kind: "gamepadAdded"timestampfield#
timestamp: numbersequencefield#
sequence: integerwindowfield#
window: integerwhichfield#
which: integerGamepadAxisrecord#
record GamepadAxis ...A gamepad axis reading.
Members
| Name | Kind | Description |
|---|---|---|
kind | field | |
timestamp | field | |
sequence | field | |
window | field | |
which | field | |
axis | field | |
value | field |
kindfield#
kind: "gamepadAxis"timestampfield#
timestamp: numbersequencefield#
sequence: integerwindowfield#
window: integerwhichfield#
which: integeraxisfield#
axis: integervaluefield#
value: numberGamepadAxisEventtype#
type GamepadAxisEvent = GamepadAxisA gamepad axis reading.
GamepadButtonDownrecord#
record GamepadButtonDown ...A gamepad button going down.
Members
| Name | Kind | Description |
|---|---|---|
kind | field | |
timestamp | field | |
sequence | field | |
window | field | |
which | field | |
button | field | |
down | field |
kindfield#
kind: "gamepadButtonDown"timestampfield#
timestamp: numbersequencefield#
sequence: integerwindowfield#
window: integerwhichfield#
which: integerbuttonfield#
button: integerdownfield#
down: booleanGamepadButtonEventtype#
type GamepadButtonEvent = GamepadButtonDown | GamepadButtonUpA gamepad button transition.
Whichever kind carries this shape; an observer written against it fits any of them.
GamepadButtonUprecord#
record GamepadButtonUp ...A gamepad button coming up.
Members
| Name | Kind | Description |
|---|---|---|
kind | field | |
timestamp | field | |
sequence | field | |
window | field | |
which | field | |
button | field | |
down | field |
kindfield#
kind: "gamepadButtonUp"timestampfield#
timestamp: numbersequencefield#
sequence: integerwindowfield#
window: integerwhichfield#
which: integerbuttonfield#
button: integerdownfield#
down: booleanGamepadDeviceEventtype#
type GamepadDeviceEvent = GamepadAdded | GamepadRemovedA gamepad appearing or going away.
Compatibility surface: which names the device rather than the window. window is zero because a gamepad belongs to no window.
Whichever kind carries this shape; an observer written against it fits any of them.
GamepadRemovedrecord#
record GamepadRemoved ...A gamepad going away.
kindfield#
kind: "gamepadRemoved"timestampfield#
timestamp: numbersequencefield#
sequence: integerwindowfield#
window: integerwhichfield#
which: integerKeyDownrecord#
record KeyDown ...A key going down.
Members
| Name | Kind | Description |
|---|---|---|
kind | field | |
timestamp | field | |
sequence | field | |
window | field | |
physicalKey | field | |
logicalKey | field | |
text | field | |
modifiers | field | |
repeated | field | |
down | field |
kindfield#
kind: "keyDown"timestampfield#
timestamp: numbersequencefield#
sequence: integerwindowfield#
window: integerphysicalKeyfield#
physicalKey: stringlogicalKeyfield#
logicalKey: string?modifiersfield#
modifiers: integerrepeatedfield#
repeated: booleandownfield#
down: booleanKeyEventtype#
A physical and logical keyboard transition.
Whichever kind carries this shape; an observer written against it fits any of them.
KeyUprecord#
record KeyUp ...A key coming up.
Members
| Name | Kind | Description |
|---|---|---|
kind | field | |
timestamp | field | |
sequence | field | |
window | field | |
physicalKey | field | |
logicalKey | field | |
text | field | |
modifiers | field | |
repeated | field | |
down | field |
kindfield#
kind: "keyUp"timestampfield#
timestamp: numbersequencefield#
sequence: integerwindowfield#
window: integerphysicalKeyfield#
physicalKey: stringlogicalKeyfield#
logicalKey: string?modifiersfield#
modifiers: integerrepeatedfield#
repeated: booleandownfield#
down: booleanKindtype#
type Kind = "quit"
| "windowCloseRequested"
| "windowResized"
| "windowScaleChanged"
| "windowFocusGained"
| "windowFocusLost"
| "keyDown"
| "keyUp"
| "mouseMotion"
| "mouseDown"
| "mouseUp"
| "mouseWheel"
| "textInput"
| "fingerDown"
| "fingerUp"
| "fingerMotion"
| "fingerCanceled"
| "gamepadAdded"
| "gamepadRemoved"
| "gamepadButtonDown"
| "gamepadButtonUp"
| "gamepadAxis"A platform event kind supported by the Rust host.
MouseDownrecord#
record MouseDown ...A pointer button going down.
Members
| Name | Kind | Description |
|---|---|---|
kind | field | |
timestamp | field | |
sequence | field | |
window | field | |
x | field | |
y | field | |
button | field | |
clicks | field | |
down | field |
kindfield#
kind: "mouseDown"timestampfield#
timestamp: numbersequencefield#
sequence: integerwindowfield#
window: integerxfield#
x: numberyfield#
y: numberbuttonfield#
button: integerclicksfield#
clicks: integerdownfield#
down: booleanMouseMotionrecord#
record MouseMotion ...An absolute pointer position and optional relative movement.
kindfield#
kind: "mouseMotion"timestampfield#
timestamp: numbersequencefield#
sequence: integerwindowfield#
window: integerxfield#
x: numberyfield#
y: numberdxfield#
dx: numberdyfield#
dy: numberMouseUprecord#
record MouseUp ...A pointer button coming up.
Members
| Name | Kind | Description |
|---|---|---|
kind | field | |
timestamp | field | |
sequence | field | |
window | field | |
x | field | |
y | field | |
button | field | |
clicks | field | |
down | field |
kindfield#
kind: "mouseUp"timestampfield#
timestamp: numbersequencefield#
sequence: integerwindowfield#
window: integerxfield#
x: numberyfield#
y: numberbuttonfield#
button: integerclicksfield#
clicks: integerdownfield#
down: booleanMouseWheelrecord#
record MouseWheel ...A normalized pointer wheel movement.
Members
| Name | Kind | Description |
|---|---|---|
kind | field | |
timestamp | field | |
sequence | field | |
window | field | |
x | field | |
y | field | |
wheelX | field | |
wheelY | field | |
wheelTicksX | field | |
wheelTicksY | field |
kindfield#
kind: "mouseWheel"timestampfield#
timestamp: numbersequencefield#
sequence: integerwindowfield#
window: integerxfield#
x: numberyfield#
y: numberwheelXfield#
wheelX: numberwheelYfield#
wheelY: numberwheelTicksXfield#
wheelTicksX: integerwheelTicksYfield#
wheelTicksY: integerPointerButtonEventtype#
A pointer button transition.
Whichever kind carries this shape; an observer written against it fits any of them.
PointerMoveEventtype#
type PointerMoveEvent = MouseMotionAn absolute pointer position and optional relative movement.
Quitrecord#
record Quit ...A process quit request.
kindfield#
kind: "quit"timestampfield#
timestamp: numbersequencefield#
sequence: integerwindowfield#
window: integerQuitEventtype#
type QuitEvent = Quit | WindowCloseRequestedA process or window close request.
Whichever kind carries this shape; an observer written against it fits any of them.
ResizeEventtype#
type ResizeEvent = WindowResized | WindowScaleChangedA logical window size change.
Whichever kind carries this shape; an observer written against it fits any of them.
TextEventtype#
type TextEvent = TextInputText committed by the platform input method.
TextInputrecord#
record TextInput ...Text committed by the platform input method.
kindfield#
kind: "textInput"timestampfield#
timestamp: numbersequencefield#
sequence: integerwindowfield#
window: integerTouchEventtype#
type TouchEvent = FingerDown | FingerUp | FingerMotion | FingerCanceledOne finger on a touch surface.
Compatibility surface: touchDevice and finger are stable field names, and both stay strings because a device and a finger are 64-bit identities that a Lua number would round together.
Whichever kind carries this shape; an observer written against it fits any of them.
WheelEventtype#
type WheelEvent = MouseWheelA normalized pointer wheel movement.
WindowCloseRequestedrecord#
record WindowCloseRequested ...A close request for one window.
kindfield#
kind: "windowCloseRequested"timestampfield#
timestamp: numbersequencefield#
sequence: integerwindowfield#
window: integerWindowFocusGainedrecord#
record WindowFocusGained ...A window gaining focus.
kindfield#
kind: "windowFocusGained"timestampfield#
timestamp: numbersequencefield#
sequence: integerwindowfield#
window: integerWindowFocusLostrecord#
record WindowFocusLost ...A window losing focus.
kindfield#
kind: "windowFocusLost"timestampfield#
timestamp: numbersequencefield#
sequence: integerwindowfield#
window: integerWindowResizedrecord#
record WindowResized ...A logical window resize.
Members
| Name | Kind | Description |
|---|---|---|
kind | field | |
timestamp | field | |
sequence | field | |
window | field | |
width | field | |
height | field | |
pixelWidth | field | |
pixelHeight | field | |
scaleFactor | field |
kindfield#
kind: "windowResized"timestampfield#
timestamp: numbersequencefield#
sequence: integerwindowfield#
window: integerwidthfield#
width: integerheightfield#
height: integerpixelWidthfield#
pixelWidth: integerpixelHeightfield#
pixelHeight: integerscaleFactorfield#
scaleFactor: numberWindowScaleChangedrecord#
record WindowScaleChanged ...A scale-factor change with the resulting logical size.
Members
| Name | Kind | Description |
|---|---|---|
kind | field | |
timestamp | field | |
sequence | field | |
window | field | |
width | field | |
height | field | |
pixelWidth | field | |
pixelHeight | field | |
scaleFactor | field |
kindfield#
kind: "windowScaleChanged"timestampfield#
timestamp: numbersequencefield#
sequence: integerwindowfield#
window: integerwidthfield#
width: integerheightfield#
height: integerpixelWidthfield#
pixelWidth: integerpixelHeightfield#
pixelHeight: integerscaleFactorfield#
scaleFactor: numberFunctions#
closeRequestedfunction#
function closeRequested(window: integer?, timestamp: number?, sequence: integer?): QuitEventConstructs a close request for one window.
Arguments
| Name | Type | Description |
|---|---|---|
window | integer? | |
timestamp | number? | |
sequence | integer? |
Returns
| Type | Description |
|---|---|
QuitEvent |
dispatchfunction#
Delivers one translated event to the world's observers of its kind.
The host's instance is delivered as it is: nothing is copied or constructed, and observers receive it as a borrow for the call.
Arguments
| Name | Type | Description |
|---|---|---|
exclusive world | ecs.World | the receiving world |
event | Event | the translated platform event |
Returns
| Type | Description |
|---|---|
nil |
focusedfunction#
function focused(focused: boolean, window: integer?, timestamp: number?, sequence: integer?): FocusEventConstructs a window focus transition.
Arguments
| Name | Type | Description |
|---|---|---|
focused | boolean | |
window | integer? | |
timestamp | number? | |
sequence | integer? |
Returns
| Type | Description |
|---|---|
FocusEvent |
gamepadAxisfunction#
function gamepadAxis(which: integer, axis: integer, value: number, timestamp: number?, sequence: integer?): GamepadAxisEventConstructs a gamepad axis reading.
Arguments
| Name | Type | Description |
|---|---|---|
which | integer | the device identifier the backend issued |
axis | integer | the axis code |
value | number | the reading from -1 to 1, with a trigger running zero to one |
timestamp | number? | the host time the platform reported |
sequence | integer? | the host's ordering number for the batch |
Returns
| Type | Description |
|---|---|
GamepadAxisEvent | the constructed axis event |
Raises
| Type | Condition |
|---|---|
string | when the axis code is not positive |
gamepadButtonfunction#
function gamepadButton(down: boolean, which: integer, button: integer, timestamp: number?, sequence: integer?): GamepadButtonEventConstructs a gamepad button transition.
Arguments
| Name | Type | Description |
|---|---|---|
down | boolean | whether the button went down rather than came up |
which | integer | the device identifier the backend issued |
button | integer | the positional button code |
timestamp | number? | the host time the platform reported |
sequence | integer? | the host's ordering number for the batch |
Returns
| Type | Description |
|---|---|
GamepadButtonEvent | the constructed button event |
Raises
| Type | Condition |
|---|---|
string | when the button code is not positive |
gamepadDevicefunction#
function gamepadDevice(added: boolean, which: integer, timestamp: number?, sequence: integer?): GamepadDeviceEventConstructs a gamepad appearing or going away.
Arguments
| Name | Type | Description |
|---|---|---|
added | boolean | whether the device appeared rather than went away |
which | integer | the device identifier the backend issued |
timestamp | number? | the host time the platform reported |
sequence | integer? | the host's ordering number for the batch |
Returns
| Type | Description |
|---|---|
GamepadDeviceEvent | the constructed device event |
keyfunction#
function key(down: boolean, physicalKey: string, logicalKey: string?, text: string?, modifiers: integer?, repeated: boolean?, window: integer?, timestamp: number?, sequence: integer?): KeyEventConstructs a keyboard transition.
Arguments
| Name | Type | Description |
|---|---|---|
down | boolean | |
physicalKey | string | |
logicalKey | string? | |
text | string? | |
modifiers | integer? | |
repeated | boolean? | |
window | integer? | |
timestamp | number? | |
sequence | integer? |
Returns
| Type | Description |
|---|---|
KeyEvent |
kindsfunction#
function kinds(): {string}Returns every platform event kind, in the union's declared order.
Compatibility surface: each string is the externally typed kind an agent names over the debug protocol, so the spellings here are the same ones Kind declares and must not change with a module move. The union is a type and cannot be read at run time, so a caller that needs the kinds as data reads them here rather than keeping a second copy that drifts.
Returns
| Type | Description |
|---|---|
{string} | a fresh caller-owned list of the twenty-two kind strings |
pointerButtonfunction#
function pointerButton(down: boolean, button: integer, x: number, y: number, clicks: integer?, window: integer?, timestamp: number?, sequence: integer?): PointerButtonEventConstructs a pointer button transition.
Arguments
| Name | Type | Description |
|---|---|---|
down | boolean | |
button | integer | |
x | number | |
y | number | |
clicks | integer? | |
window | integer? | |
timestamp | number? | |
sequence | integer? |
Returns
| Type | Description |
|---|---|
PointerButtonEvent |
pointerMovedfunction#
function pointerMoved(x: number, y: number, dx: number?, dy: number?, window: integer?, timestamp: number?, sequence: integer?): PointerMoveEventConstructs an absolute pointer movement.
Arguments
| Name | Type | Description |
|---|---|---|
x | number | |
y | number | |
dx | number? | |
dy | number? | |
window | integer? | |
timestamp | number? | |
sequence | integer? |
Returns
| Type | Description |
|---|---|
PointerMoveEvent |
quitfunction#
function quit(window: integer?, timestamp: number?, sequence: integer?): QuitEventConstructs a process or window close request.
Arguments
| Name | Type | Description |
|---|---|---|
window | integer? | |
timestamp | number? | |
sequence | integer? |
Returns
| Type | Description |
|---|---|
QuitEvent |
resizedfunction#
function resized(width: integer, height: integer, window: integer?, scaleFactor: number?, timestamp: number?, sequence: integer?, pixelWidth: integer?, pixelHeight: integer?): ResizeEventConstructs a logical window resize.
Arguments
| Name | Type | Description |
|---|---|---|
width | integer | |
height | integer | |
window | integer? | |
scaleFactor | number? | |
timestamp | number? | |
sequence | integer? | |
pixelWidth | integer? | |
pixelHeight | integer? |
Returns
| Type | Description |
|---|---|
ResizeEvent |
scaleChangedfunction#
function scaleChanged(scaleFactor: number, width: integer, height: integer, window: integer?, timestamp: number?, sequence: integer?, pixelWidth: integer?, pixelHeight: integer?): ResizeEventConstructs a scale-factor change with the resulting logical size.
Arguments
| Name | Type | Description |
|---|---|---|
scaleFactor | number | |
width | integer | |
height | integer | |
window | integer? | |
timestamp | number? | |
sequence | integer? | |
pixelWidth | integer? | |
pixelHeight | integer? |
Returns
| Type | Description |
|---|---|
ResizeEvent |
textfunction#
Constructs committed text input.
Arguments
| Name | Type | Description |
|---|---|---|
text | string | |
window | integer? | |
timestamp | number? | |
sequence | integer? |
Returns
| Type | Description |
|---|---|
TextEvent |
touchfunction#
function touch(phase: "fingerDown" | "fingerUp" | "fingerMotion" | "fingerCanceled", touchDevice: string, finger: string, x: number, y: number, normalX: number?, normalY: number?, pressure: number?, dx: number?, dy: number?, window: integer?, timestamp: number?, sequence: integer?): TouchEventConstructs one finger's transition or movement.
x and y are in the window's logical coordinates, normalX and normalY run from zero to one across the touch surface, and pressure runs from zero to one where the surface reports it and is one where it does not.
Arguments
| Name | Type | Description |
|---|---|---|
phase | "fingerDown" | "fingerUp" | "fingerMotion" | "fingerCanceled" | the finger's transition, spelled as the event kind |
touchDevice | string | the touch surface's opaque identity |
finger | string | the finger's opaque identity on that surface |
x | number | the position in logical window coordinates |
y | number | the position in logical window coordinates |
normalX | number? | the position across the surface, from zero to one |
normalY | number? | the position down the surface, from zero to one |
pressure | number? | the reported pressure from zero to one |
dx | number? | the movement since the previous event, in logical coordinates |
dy | number? | the movement since the previous event, in logical coordinates |
window | integer? | the window the touch is over |
timestamp | number? | the host time the platform reported |
sequence | integer? | the host's ordering number for the batch |
Returns
| Type | Description |
|---|---|
TouchEvent | the constructed touch event |
Raises
| Type | Condition |
|---|---|
string | when the finger identity is empty |
wheelfunction#
function wheel(wheelX: number, wheelY: number, ticksX: integer?, ticksY: integer?, x: number?, y: number?, window: integer?, timestamp: number?, sequence: integer?): WheelEventConstructs normalized pointer wheel movement.
Arguments
| Name | Type | Description |
|---|---|---|
wheelX | number | |
wheelY | number | |
ticksX | integer? | |
ticksY | integer? | |
x | number? | |
y | number? | |
window | integer? | |
timestamp | number? | |
sequence | integer? |
Returns
| Type | Description |
|---|---|
WheelEvent |