Skip to main content

ItemSelectionEventTriggers Class

Definition

Assembly:Avalonia.Controls
Package:Avalonia

Defines standard logic for selecting items via user input. Behaviour differs between input devices.

public class ItemSelectionEventTriggers

Inheritance: object -> ItemSelectionEventTriggers

Methods

NameDescription
HasRangeSelectionModifierAnalyses an input event received by a selectable element, and determines whether the action should trigger range selection.
HasToggleSelectionModifierAnalyses an input event received by a selectable element, and determines whether the action should trigger toggle selection.
ShouldTriggerSelection (2 overloads)Analyses an input event received by a selectable element, and determines whether the action should trigger selection on press, on release, or not at all.

HasRangeSelectionModifier Method

Analyses an input event received by a selectable element, and determines whether the action should trigger range selection.

public bool HasRangeSelectionModifier(Avalonia.Visual selectable, Avalonia.Interactivity.RoutedEventArgs eventArgs)

Parameters

selectable Avalonia.Visual

The selectable element which is processing the event.

eventArgs Avalonia.Interactivity.RoutedEventArgs

The event to analyse.

Returns

bool

See also

HasToggleSelectionModifier Method

Analyses an input event received by a selectable element, and determines whether the action should trigger toggle selection.

public bool HasToggleSelectionModifier(Avalonia.Visual selectable, Avalonia.Interactivity.RoutedEventArgs eventArgs)

Parameters

selectable Avalonia.Visual

The selectable element which is processing the event.

eventArgs Avalonia.Interactivity.RoutedEventArgs

The event to analyse.

Returns

bool

See also

ShouldTriggerSelection overloads

ShouldTriggerSelection Method

Analyses an input event received by a selectable element, and determines whether the action should trigger selection on press, on release, or not at all.

public bool ShouldTriggerSelection(Avalonia.Visual selectable, Avalonia.Input.KeyEventArgs eventArgs)
Parameters

selectable Avalonia.Visual

The selectable element which is processing the event.

eventArgs Avalonia.Input.KeyEventArgs

The event to analyse.

Returns

bool

ShouldTriggerSelection Method

Analyses an input event received by a selectable element, and determines whether the action should trigger selection on press, on release, or not at all.

public bool ShouldTriggerSelection(Avalonia.Visual selectable, Avalonia.Input.PointerEventArgs eventArgs)
Parameters

selectable Avalonia.Visual

The selectable element which is processing the event.

eventArgs Avalonia.Input.PointerEventArgs

The event to analyse.

Returns

bool