Skip to main content

UpdateSelection(Int32, Boolean, Boolean, Boolean, Boolean, Boolean) Method

Updates the selection for an item based on user interaction.

Definition​

Namespace: Avalonia.Controls.Primitives
Assembly: Avalonia.Controls (in Avalonia.Controls.dll)

protected void UpdateSelection(
int index,
bool select = true,
bool rangeModifier = false,
bool toggleModifier = false,
bool rightButton = false,
bool fromFocus = false
)

Parameters​

  Int32
The index of the item.
  Boolean  (Optional)
Whether the item should be selected or unselected.
  Boolean  (Optional)
Whether the range modifier is enabled (i.e. shift key).
  Boolean  (Optional)
Whether the toggle modifier is enabled (i.e. ctrl key).
  Boolean  (Optional)
Whether the event is a right-click.
  Boolean  (Optional)
Wheter the event is a focus event

See Also​

Reference​

SelectingItemsControl Class
UpdateSelection Overload
Avalonia.Controls.Primitives Namespace