SelectorAutomationPeer SelectorAutomationPeer SelectorAutomationPeer Class

A base class that provides a Microsoft UI Automation peer implementation for types that derive from Selector.

Syntax

Declaration

public class SelectorAutomationPeerpublic class SelectorAutomationPeerPublic Class SelectorAutomationPeer

Inheritance Hierarchy

Inherited Members

Inherited methods

, , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,

Inherited properties

, ,

Windows.UI.Xaml.Automation.Peers.AutomationPeer.RaiseTextEditTextChangedEvent(Windows.UI.Xaml.Automation.AutomationTextEditChangeType,Windows.Foundation.Collections.IVectorView<System.String>)
Windows.UI.Xaml.Automation.Peers.AutomationPeer.RaiseTextEditTextChangedEvent(Windows.UI.Xaml.Automation.AutomationTextEditChangeType,Windows.Foundation.Collections.IVectorView<System.String>)
Windows.UI.Xaml.Automation.Peers.AutomationPeer.RaiseTextEditTextChangedEvent(Windows.UI.Xaml.Automation.AutomationTextEditChangeType,Windows.Foundation.Collections.IVectorView<System.String>)

Remarks

The Windows Runtime Selector class creates a new SelectorAutomationPeer as part of internal logic that checks for listeners of certain automation events. Selector doesn't have an OnCreateAutomationPeer() that automatically hooks up the peer on creation, because Selector is usually a base class.

Selector has several derived classes such as ListBox, which have template support and practical implementations of some important functionality. Make sure that you really want to derive from the base class. If you're sure you want to derive from Selector, directly, derive your automation peer from SelectorAutomationPeer and override OnCreateAutomationPeer() so that it returns your custom peer.

Default peer implementation and overrides in SelectorAutomationPeer

SelectorAutomationPeer has overrides of Core methods such that the associated AutomationPeer methods provide peer-specific information to a Microsoft UI Automation client.

The peer also has other behaviors that are provided by the base FrameworkElementAutomationPeer class. For more info, see "Base implementation in FrameworkElementAutomationPeer" section of Custom automation peers.

SelectorAutomationPeer derived classes

SelectorAutomationPeer is the parent class for these classes:

Constructors summary

Initializes a new instance of the SelectorAutomationPeer class.

Properties summary

Gets a value that indicates whether the Microsoft UI Automation provider allows more than one child element to be selected concurrently.

Gets a value that indicates whether the Microsoft UI Automation provider requires at least one child element to be selected.

Methods summary

Retrieves a Microsoft UI Automation provider for each child element that is selected.

Constructors

  • SelectorAutomationPeer(Selector)
    SelectorAutomationPeer(Selector)
    SelectorAutomationPeer(Selector)
    SelectorAutomationPeer(Selector)

    Initializes a new instance of the SelectorAutomationPeer class.

    public SelectorAutomationPeer(Selector owner)public New(Selector owner)Public Sub New(owner As Selector)public SelectorAutomationPeer(Selector owner)

    Parameters

Properties

  • CanSelectMultiple
    CanSelectMultiple
    CanSelectMultiple
    CanSelectMultiple

    Gets a value that indicates whether the Microsoft UI Automation provider allows more than one child element to be selected concurrently.

    public bool CanSelectMultiple { get; }public bool CanSelectMultiple { get; }Public ReadOnly Property CanSelectMultiple As boolpublic bool CanSelectMultiple { get; }

    Property Value

    • bool
      bool
      bool

      true if multiple selection is allowed; otherwise, false.

  • IsSelectionRequired
    IsSelectionRequired
    IsSelectionRequired
    IsSelectionRequired

    Gets a value that indicates whether the Microsoft UI Automation provider requires at least one child element to be selected.

    public bool IsSelectionRequired { get; }public bool IsSelectionRequired { get; }Public ReadOnly Property IsSelectionRequired As boolpublic bool IsSelectionRequired { get; }

    Property Value

    • bool
      bool
      bool

      true if selection is required; otherwise, false.

Methods

  • GetSelection()
    GetSelection()
    GetSelection()
    GetSelection()

    Retrieves a Microsoft UI Automation provider for each child element that is selected.

    public IRawElementProviderSimple[] GetSelection()public IRawElementProviderSimple[] GetSelection()Public Function GetSelection() As IRawElementProviderSimple[]public IRawElementProviderSimple[] GetSelection()

    Returns

    • Windows.UI.Xaml.Automation.Provider.IRawElementProviderSimple[]
      Windows.UI.Xaml.Automation.Provider.IRawElementProviderSimple[]
      Windows.UI.Xaml.Automation.Provider.IRawElementProviderSimple[]

      A generic list of Microsoft UI Automation providers.

Device family

Windows 10 (introduced v10.0.10240.0)

API contract

Windows.Foundation.UniversalApiContract (introduced v1)

Attributes

Windows.Foundation.Metadata.ComposableAttribute
Windows.Foundation.Metadata.ContractVersionAttribute
Windows.Foundation.Metadata.MarshalingBehaviorAttribute
Windows.Foundation.Metadata.ThreadingAttribute
Windows.Foundation.Metadata.WebHostHiddenAttribute

Details

Assembly

Windows.UI.Xaml.Automation.Peers.dll