| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Code-Review | +1 |
nit: It might be good to have some event dump tests covering this, but not a blocker IMO.
lgtm!
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Code-Review | +1 |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
[UIA] Raise ExpandCollapseState for expand-collapse button state changes
While working on ViewsAX, we discovered a bug that affects menu buttons
on web content (and with ViewsAX enabled). This CL fixes it.
To understand the bug, we must first understand that, in UIA, we differentiate toggled buttons based on whether they are a genuine toggle or whether they have an associated menus. A generic toggle button, like a checkbox, should support the ToggleState pattern, and a toggle button associated with a menu (referenced to as a menu button) should instead support the ExpandCollapseState pattern. Those patterns should be mutually exclusive (see [1]).
The pattern was already properly exposed from a previous CL I did a long time ago. However, what was uncovered here is that, for menu button, while we expose the right pattern, we still fire the wrong event: we raise ToggleState changed event. This was incorrect.
To fix this, we introduce a new helper AXPlatformNodeWin::IsExpandCollapseButton to avoid repeating logic, and reuse it for both the state exposed and the event fired.
[1]: https://source.chromium.org/chromium/chromium/src/+/main:ui/accessibility/platform/ax_platform_node_win.cc;l=9165?q=IsToggleSupported&ss=chromium
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |