You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fix FindAll missing elements after WebView2 controls
UIA FindAll(TreeScope_Descendants) can stall in the WebView2 Chromium
UIA provider subtree, causing sibling elements after the WebView to be
silently skipped. This caused 'search StatusBar' and 'get-value
StatusBar' to return 0 results even though 'inspect' (which uses
TreeWalker) found the element.
Added ManualTreeSearch fallback that uses TreeWalker
(GetFirstChildElement/GetNextSiblingElement) to walk the tree
sibling-by-sibling. This is the same traversal method inspect uses.
The fallback activates when FindAll returns 0 results.
Applied to both SearchAsync and FindSingleElementAsync.
Root cause verified with repro app: StatusBar Edit at depth 3 was a
sibling after PreviewWebView Pane. FindAll found elements before the
WebView but not after. Manual tree walk found it reliably.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
0 commit comments