/// <summary> /// Provides initialization for base class values when called by the constructor /// of a derived class. /// </summary> /// <param name="item">The item to create the automation peer for.</param> /// <returns>The item automation peer.</returns> protected override ItemAutomationPeer CreateItemAutomationPeer(object item) { ItemAutomationPeer peer = null; UIElement element = item as UIElement; if (element != null) { peer = FrameworkElementAutomationPeer.CreatePeerForElement(element) as ItemAutomationPeer; } return(peer); }
protected override ItemAutomationPeer CreateItemAutomationPeer(object item) { ItemAutomationPeer peer = CategoryContainerAutomationPeer.CreateItemAutomationPeer( item as ModelCategoryEntry, _control.ItemContainerGenerator.ContainerFromItem(item) as CiderCategoryContainer, this); //Add each item to the children's list _children.Add(peer); return(peer); }
internal static UIElement GetWrapper(this ItemAutomationPeer automationPeer) { return((UIElement)getWrapperMethodInfo.Invoke(automationPeer, null)); }
internal static AutomationPeer GetWrapperPeer(this ItemAutomationPeer automationPeer) { return((AutomationPeer)getWrapperPeerMethodInfo.Invoke(automationPeer, null)); }