struct InputEvent
Swift
Constructors
init(kind: InputEventKind, x: Float, y: Float, button: Int32, mods: Int32 = 0)
Creates an event.
Sources/LavaUI/Input.swift:308
Properties
var button: Int32
Integer payload. Its meaning depends on kind.
Sources/LavaUI/Input.swift:301
var keyAction: Float { get }
For a .key event, the action (KeyAction).
Sources/LavaUI/Input.swift:319
var keyMods: Int32 { get }
For a .key event, the modifier bits (KeyMods).
Sources/LavaUI/Input.swift:321
var kind: InputEventKind
What happened; decides how the other fields read.
Sources/LavaUI/Input.swift:295
var mods: Int32
GLFW modifier bitfield (see KeyMods). Only populated for
.mouseDown/.mouseUp — .scroll already carries mods in button,
.key carries them in y.
Sources/LavaUI/Input.swift:305
var x: Float
First payload value. Its meaning depends on kind.
Sources/LavaUI/Input.swift:297
var y: Float
Second payload value. Its meaning depends on kind.
Sources/LavaUI/Input.swift:299