In This Article

BarButtonAutomationPeer Class

Exposes BarButton types to UI Automation.

public class BarButtonAutomationPeer : ButtonAutomationPeer
Inheritance:
object AutomationPeer UIElementAutomationPeer FrameworkElementAutomationPeer ButtonBaseAutomationPeer ButtonAutomationPeer object
Derived:
BarToggleButtonAutomationPeer

Constructors

BarButtonAutomationPeer(BarButton)

Initializes a new instance of the BarButtonAutomationPeer class.

public BarButtonAutomationPeer(BarButton owner)
Parameter Type Description
owner BarButton

The owner element.

Methods

GetAutomationIdCore()

Gets the System.Windows.Automation.AutomationProperties.AutomationId for the element associated with this ButtonBaseAutomationPeer. Called by GetAutomationId().

protected override string GetAutomationIdCore()

Returns

string:

The string that contains the System.Windows.Automation.AutomationProperties.AutomationId.

GetChildrenCore()

Gets the collection of child elements of the UIElement that is associated with this UIElementAutomationPeer. This method is called by GetChildren().

protected override List<AutomationPeer> GetChildrenCore()

Returns

List<AutomationPeer>:

A list of child AutomationPeer elements.

GetClassNameCore()

Gets the name of the control that is associated with this UI Automation peer.

protected override string GetClassNameCore()

Returns

string:

A string that contains "Button".

GetLocalizedControlTypeCore()

When overridden in a derived class, is called by GetLocalizedControlType().

protected override string GetLocalizedControlTypeCore()

Returns

string:

The type of the control.

GetNameCore()

Gets the name of the class of the element associated with this ButtonBaseAutomationPeer. Called by GetName().

protected override string GetNameCore()

Returns

string:

A string that contains the class name, minus the accelerator key.