Table of Contents

Struct PointerEventRef

Namespace
Xui.Core.UI.Input
Assembly
Core.dll

Represents a reference to a pointer event routed to a view, containing identification and pointer state information.

public ref struct PointerEventRef
Inherited Members

Constructors

PointerEventRef(PointerEventType, int, long, bool, PointerState, ReadOnlySpan<PointerState>, ReadOnlySpan<PointerState>)

Initializes a new instance of the PointerEventRef struct.

public PointerEventRef(PointerEventType type, int pointerId, long persistentDeviceId, bool isPrimary, PointerState state, ReadOnlySpan<PointerState> coalescedStates, ReadOnlySpan<PointerState> predictedStates)

Parameters

type PointerEventType

The type of pointer event (Down, Move, Up, etc.).

pointerId int

The unique ID of the pointer.

persistentDeviceId long

The persistent ID of the physical device, if available.

isPrimary bool

Indicates whether this pointer is the primary pointer.

state PointerState

The current physical state of the pointer.

coalescedStates ReadOnlySpan<PointerState>

High-frequency samples coalesced since the last event.

predictedStates ReadOnlySpan<PointerState>

Future-predicted samples for smoothing or latency compensation.

Fields

CoalescedStates

Gets high-frequency coalesced samples recorded between the last and current events.

public readonly ReadOnlySpan<PointerState> CoalescedStates

Field Value

ReadOnlySpan<PointerState>

IsPrimary

Gets a value indicating whether this pointer is the primary pointer in a multi-pointer interaction (e.g., first touch).

public readonly bool IsPrimary

Field Value

bool

PersistentDeviceId

Gets the persistent device ID, if known. Identifies the underlying hardware across multiple pointer sessions.

public readonly long PersistentDeviceId

Field Value

long

PointerId

Gets the unique ID of the pointer. Used to distinguish different active pointers (e.g., different fingers or pen tips).

public readonly int PointerId

Field Value

int

PredictedStates

Gets future-predicted samples estimated from the current pointer movement.

public readonly ReadOnlySpan<PointerState> PredictedStates

Field Value

ReadOnlySpan<PointerState>

State

Gets the current physical state of the pointer (position, pressure, tilt, etc.).

public readonly PointerState State

Field Value

PointerState

Type

Gets the type of pointer event (e.g., Down, Move, Up, Enter, Leave).

public readonly PointerEventType Type

Field Value

PointerEventType