Invalidate aria-hidden subtree to update accessibility ignored and invisible states
This CL addresses a Blink Accessibility invalidation gap, when a node's aria-hidden state changes, its blink accessibility subtree must also be invalidated so that the accessibility ignored and invisible states are serialized to the browser process. This is important because we rely on these states being accurate in the browser process, and we need need to receive the state changes through AXEventGenerator in order to send appropriate platform accessibility events, such as structure change events (add/remove child, hide/show, or 'children-changed'). Adding AXObjectCacheImpl::HandleAriaHiddenChangedWithCleanLayout which handles this invalidation, and immediately handles ChildrenChangedWithCleanLayout on the parent of the modified node, and increments |modification_count_| to invalidate AXObject cached values. e.g. AccessibilityIsIgnored(), and IsInertOrAriaHidden(). I needed to also modify BrowserAccessibilityWin::CanFireEvents to allow events to process for the corner case outlined in Bug:1159660. Because the node becoming ignored was the only child, the parent became a leaf node, and the node removed would return false for CanFireEvents because now it "IsChildOfLeaf()". I added a condition to check if the ignored state changed this frame, and if so, allow events to process. BrowserAccessibilityManagerWin filters platform events appropriately for nodes that are ignored. Bug: 1159660 Change-Id: I82e2368c09d4855fdb834600aed7ac61d1883c65 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2612365 Commit-Queue: Adam Ettenberger <Adam.Ettenberger@microsoft.com> Reviewed-by:Kurt Catti-Schmidt <kschmi@microsoft.com> Reviewed-by:
Jacques Newman <janewman@microsoft.com> Reviewed-by:
Aaron Leventhal <aleventhal@chromium.org> Cr-Commit-Position: refs/heads/master@{#846165}
Showing
Please register or sign in to comment