// internal methods public virtual object GetPatternPropertyValue(classic.AutomationProperty property, bool useCache) { if (useCache) { switch (_innerElementType) { case InnerElementTypes.AutomationElementNet: return(_elementHolderNet.GetCachedPropertyValue(property)); //case InnerElementTypes.AutomationElementCom: // case InnerElementTypes.UiElement: return(_elementHolderAdapter.GetCachedPropertyValue(property)); default: return(_elementHolderNet.GetCachedPropertyValue(property)); } } switch (_innerElementType) { case InnerElementTypes.AutomationElementNet: return(_elementHolderNet.GetCurrentPropertyValue(property)); //case InnerElementTypes.AutomationElementCom: // case InnerElementTypes.UiElement: return(_elementHolderAdapter.GetCurrentPropertyValue(property)); default: return(_elementHolderNet.GetCurrentPropertyValue(property)); } }
public virtual object GetCurrentPropertyValue(classic.AutomationProperty property) { switch (_innerElementType) { case InnerElementTypes.AutomationElementNet: return(Preferences.FromCache ? _elementHolderNet.GetCachedPropertyValue(property) : _elementHolderNet.GetCurrentPropertyValue(property)); // case InnerElementTypes.AutomationElementCom: // // case InnerElementTypes.UiElement: return(Preferences.FromCache ? _elementHolderAdapter.GetCachedPropertyValue(property) : _elementHolderAdapter.GetCurrentPropertyValue(property)); default: return(Preferences.FromCache ? _elementHolderNet.GetCachedPropertyValue(property) : _elementHolderNet.GetCurrentPropertyValue(property)); } }
public virtual object GetCachedPropertyValue(classic.AutomationProperty property, bool ignoreDefaultValue) { switch (_innerElementType) { case InnerElementTypes.AutomationElementNet: return(_elementHolderNet.GetCachedPropertyValue(property, ignoreDefaultValue)); // case InnerElementTypes.AutomationElementCom: // // case InnerElementTypes.UiElement: return(_elementHolderAdapter.GetCachedPropertyValue(property, ignoreDefaultValue)); default: return(_elementHolderNet.GetCachedPropertyValue(property, ignoreDefaultValue)); } }
public string PropertyName(classic.AutomationProperty property) { return(classic.Automation.PropertyName(property)); }