Add missing AutomationPeers from built-in Controls. - #21322
Merged
Conversation
grokys
reviewed
May 7, 2026
robloo
reviewed
May 7, 2026
Flatten MenuItem children under NativeMenuBarAutomationPeer and raise ColorChanged when Color is set directly so ColorSpectrumAutomationPeer notifies AT clients.
|
You can test this PR using the following package version. |
|
You can test this PR using the following package version. |
|
You can test this PR using the following package version. |
jmacato
force-pushed
the
features/more-autopeers
branch
from
May 19, 2026 17:24
626821c to
5eae2dc
Compare
Bisect confirmed this override caused 5 Windows IT tests (Slider, Screen, DragDrop) to fail by producing an inconsistent UIA tree where MenuItem peers list NativeMenuBar as parent while their visual parent is the inner Menu. Reverted to the thin peer that only reports ControlType=MenuBar, and dropped the now-irrelevant children assertion test.
jmacato
force-pushed
the
features/more-autopeers
branch
from
May 19, 2026 18:14
30f8afd to
a9989bc
Compare
|
You can test this PR using the following package version. |
MrJul
added this pull request to the merge queue
May 19, 2026
MrJul
pushed a commit
to MrJul/Avalonia
that referenced
this pull request
May 28, 2026
* Add missing AutomationPeers from built-in Controls. * revert native menu bar peers * Add back a thin automation peer for native menu bar. * Use ColorChanged for ColorSpectrumAutomationPeer * Fix NativeMenuBar/ColorSpectrum automation peer regressions Flatten MenuItem children under NativeMenuBarAutomationPeer and raise ColorChanged when Color is set directly so ColorSpectrumAutomationPeer notifies AT clients. * Drop NativeMenuBarAutomationPeer.GetChildrenCore override Bisect confirmed this override caused 5 Windows IT tests (Slider, Screen, DragDrop) to fail by producing an inconsistent UIA tree where MenuItem peers list NativeMenuBar as parent while their visual parent is the inner Menu. Reverted to the thin peer that only reports ControlType=MenuBar, and dropped the now-irrelevant children assertion test.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does the pull request do?
Adds automation peers for several controls that previously used the default or is missing peer behavior:
AutoCompleteBoxCalendarCalendarDatePickerNumericUpDownSplitButtonToggleSplitButtonToolTipColorSpectrumWhat is the current behavior?
These controls either do not create a control-specific automation peer or do not expose the expected automation patterns, so accessibility/UI automation clients see incomplete or generic behavior.
What is the updated/expected behavior with this PR?
The affected controls now create dedicated automation peers and expose more accurate automation metadata and provider contracts behavior where applicable.
Checklist