Repository navigation
fix(automation): Pass owner to LoopingSelectorItem peer - #26231
Conversation
|
Claude finished @morning4coffe-dev's task in 14s —— View job Review summary
Verdict: ship. No blocking issues found, and I posted no inline comments. Issues by severity: 0 blocker, 0 major, 0 minor. I read the diff and the surrounding code. I did not build the project or run the tests.
Non-blocking: The red-before/green-after run isn't shown in the PR. The description's UIA-client check on Skia Desktop (master exposes no items, the PR exposes 33) partly covers it. |
|
🤖 Your WebAssembly Sample App stage site is ready! Visit it here: |
|
Claude finished @morning4coffe-dev's task in 14s —— View job Review summary
Verdict: ship. I found no blocking issues and posted no inline comments. Issues by severity: 0 blocker, 0 major, 0 minor. I read the diff and did not build the project or run the tests.
Non-blocking: The PR doesn't show a red-before, green-after test run. The UIA-client check in the description (master exposes no items, this PR exposes 33) partly covers that gap. |
|
🤖 Your WebAssembly Sample App stage site is ready! Visit it here: |
|
The build 244693 found UI Test snapshots differences: Details
|
GitHub Issue: closes #24183
PR Type:
🐞 Bugfix
What changed? 🚀
Opening a
DatePickerorTimePickerflyout with an automation client attached threw aNullReferenceExceptionfor every looping selector item, so screen readers couldn't see any of the picker values.Two problems, one hiding the other:
LoopingSelectorItemAutomationPeernever got its owner. The constructor didn't chain tobase(owner), soOwnerstayed null and the first property read threw. WinUI creates it withCreateInstanceWithOwner(LoopingSelectorItemAutomationPeer_Partial.cpp,InitializeImpl).GetName()hit a stub.DatePickerFlyoutItem.GetStringRepresentationthrewNotImplementedException. I ported it 1:1 fromDatePickerFlyoutItem_Partial.cpp, together with the rest of itsICustomPropertyProvidersurface (GetCustomProperty/GetIndexedPropertyreturn null,Typereturns the type,ToStringdelegates toGetStringRepresentation). The generated stub was adjusted the same way the API sync tool does it.Test:
Given_TimePicker.When_Flyout_Opened_Then_LoopingSelectorItem_Peers_Have_Owneropens the flyout and checks every item peer has an owner and a name. It's pinned to a 12-hour clock so it doesn't depend on the machine's culture.Checked with a UIA client on Skia Desktop: master exposes no picker items at all after opening the TimePicker flyout; with this change it exposes all 33, named "12", "1", ….
PR Checklist ✅
Screenshots Compare Test Runresults.🤖 Generated with Claude Code