public sealed class AccessibilityTreeSourceCaptures the accessibility tree, frame after frame, with node ids that stay put.
Remarks
The mutable half, deliberately separated from the immutable one. An AccessibilityTree is a frame that has already happened and can be read from any thread; this is the map from live elements to node ids, and it belongs to the thread that owns the document, like everything else in Vixen.Ui.
⚠ An id is never handed out twice. A removed element's id is retired rather than recycled, so a bridge holding a stale reference to node 41 gets nothing back rather than someone else's button. That is what makes the platform objects a bridge keeps — AXUIElements, UIA providers — safe to key on the id.
Usage is one call from AccessibilityInvalidated: Capture for the new tree, and Changes for what to post.
Fields and properties (2)
public AccessibilityTree? TreeThe most recent capture, or null before the first one.
public IReadOnlyList<AccessibilityChange> ChangesWhat the most recent Capture changed, against the one before it.
Methods (2)
public AccessibilityTree Capture(UiElement root)Captures the accessibility tree under an element, and diffs it against the last one.
public void Reset()Forgets every id, so the next capture is a fresh tree.
Used by (2)
- AccessibilityTreeVixen.Ui
- AccessibilityTreeTestsVixen.Ui.Tests