Skip to content

TSdlGamepadButtonEvent

Gamepad button event structure (Event.GamepadButton.* )

Definition

Unit: Neslib.Sdl3.Events

type TSdlGamepadButtonEvent = record ... end;

Properties

Name Description
Button The gamepad button
IsDown True if the button is pressed
Joystick The joystick (or nil if not opened)
JoystickID The joystick instance ID
Kind Event kind (TSdlEventKind.GamepadButtonUp/Down)
Timestamp In nanoseconds, populated using SdlGetTicksNS

Property Descriptions

Button

The gamepad button

property Button: TSdlGamepadButton read GetButton

Type: TSdlGamepadButton


IsDown

True if the button is pressed

property IsDown: Boolean read FHandle.down

Type: Boolean


Joystick

The joystick (or nil if not opened)

property Joystick: TSdlJoystick read GetJoystick

Type: TSdlJoystick


JoystickID

The joystick instance ID

property JoystickID: TSdlJoystickID read GetJoystickID

Type: TSdlJoystickID


Kind

Event kind (TSdlEventKind.GamepadButtonUp/Down)

property Kind: TSdlEventKind read GetKind

Type: TSdlEventKind


Timestamp

In nanoseconds, populated using SdlGetTicksNS

property Timestamp: UInt64 read FHandle.timestamp

Type: UInt64