Table of Contents

Class PointerEvent

Namespace
Stride.Input
Assembly
Stride.Input.dll

A pointer event.

public class PointerEvent : InputEvent, IInputEventArgs
Inheritance
PointerEvent
Implements
Inherited Members

Properties

AbsoluteDeltaPosition

Gets the absolute delta position of the pointer since the previous frame.

public Vector2 AbsoluteDeltaPosition { get; }

Property Value

Vector2

The absolute delta position.

AbsolutePosition

Gets the absolute screen position of the pointer.

public Vector2 AbsolutePosition { get; }

Property Value

Vector2

The absolute delta position.

DeltaPosition

Gets the delta position of the pointer since the previous frame.

public Vector2 DeltaPosition { get; }

Property Value

Vector2

The delta position.

DeltaTime

Gets the amount of time since the previous state.

public TimeSpan DeltaTime { get; }

Property Value

TimeSpan

The delta time.

EventType

Gets the type of pointer event (pressed,released,etc.)

public PointerEventType EventType { get; }

Property Value

PointerEventType

The state.

IsDown

Gets if the pointer is down, useful for filtering out move events that are not placed between drags

public bool IsDown { get; }

Property Value

bool

Pointer

The pointer that sent this event

public IPointerDevice Pointer { get; }

Property Value

IPointerDevice

PointerId

Gets a unique identifier of the pointer. See remarks.

public int PointerId { get; }

Property Value

int

The pointer id.

Remarks

The default mouse pointer will always be affected to the PointerId 0. On a tablet, a pen or each fingers will get a unique identifier.

Position

Gets the normalized screen position of the pointer.

public Vector2 Position { get; }

Property Value

Vector2

The position.

Methods

Clone()

Clones the pointer event, this is useful if you intend to use it after this frame, since otherwise it would be recycled by the input manager the next frame

public PointerEvent Clone()

Returns

PointerEvent

The cloned event

ToString()

Returns a string that represents the current object.

public override string ToString()

Returns

string

A string that represents the current object.