Beispiel #1
0
        /// <inheritdoc />
        public override AutomationElement FindFirstWithOptions(TreeScope treeScope, ConditionBase condition,
                                                               TreeTraversalOptions traversalOptions, AutomationElement root)
        {
            var nativeFoundElement = CacheRequest.IsCachingActive
                ? NativeElement7.FindFirstWithOptionsBuildCache((UIA.TreeScope)treeScope, ConditionConverter.ToNative(Automation, condition), CacheRequest.Current.ToNative(Automation), (UIA.TreeTraversalOptions)traversalOptions, root.ToNative())
                : NativeElement7.FindFirstWithOptions((UIA.TreeScope)treeScope, ConditionConverter.ToNative(Automation, condition), (UIA.TreeTraversalOptions)traversalOptions, root.ToNative());

            return(AutomationElementConverter.NativeToManaged(Automation, nativeFoundElement));
        }
Beispiel #2
0
 /// <inheritdoc />
 public override AutomationElement[] FindAllWithOptions(TreeScope treeScope, ConditionBase condition,
                                                        TreeTraversalOptions traversalOptions, AutomationElement root)
 {
     throw new NotSupportedByFrameworkException();
 }
 /// <summary>
 /// Finds the first matching element in the specified order.
 /// </summary>
 /// <param name="treeScope">A combination of values specifying the scope of the search.</param>
 /// <param name="condition">A condition that represents the criteria to match.</param>
 /// <param name="traversalOptions">Value specifying the tree navigation order.</param>
 /// <param name="root">An element with which to begin the search.</param>
 /// <returns>The found element or null if no element was found.</returns>
 public abstract AutomationElement FindFirstWithOptions(TreeScope treeScope, ConditionBase condition, TreeTraversalOptions traversalOptions, AutomationElement root);
Beispiel #4
0
 /// <inheritdoc />
 public AutomationElement FindFirstWithOptions(TreeScope treeScope, ConditionBase condition,
                                               TreeTraversalOptions traversalOptions, AutomationElement root)
 {
     return(FrameworkAutomationElement.FindFirstWithOptions(treeScope, condition, traversalOptions, root));
 }