Repository navigation
fix(a11y): Use owning flyout name for presenter AutomationId - #25308
MartinZikmund wants to merge 5 commits into
Conversation
|
Claude finished @MartinZikmund's task in 16s —— View job Review of the flyout owner-name AutomationId commitsI reviewed only the four commits after Verdict: ship. I found 0 blocking issues and posted no inline comments.
Minor, non-blocking:
Process:
|
edbc0f4 to
3c58139
Compare
|
🤖 Your WebAssembly Skia Sample App stage site is ready! Visit it here: https://unowasmprstaging.z20.web.core.windows.net/pr-25308/wasm-skia-net9/index.html |
3c58139 to
c6e8d1f
Compare
|
Claude finished @MartinZikmund's task in 27s —— View job Review: flyout owner-name AutomationIdI reviewed only the five commits on top of Verdict: ship. I found no blocking issues and posted no inline comments.
Cross-cutting, from the lower PRs in the stack (not this PR's commits):
|
|
🤖 Your Docs stage site is ready! Visit it here: https://unodocsprstaging.z13.web.core.windows.net/pr-25308/docs/index.html |
c6e8d1f to
c7ea227
Compare
|
Claude finished @MartinZikmund's task in 12s —— View job Review: flyout owner-name AutomationIdYou mentioned Verdict: ship. I found no blocking issues and posted no inline comments.
Minor, non-blocking:
Cross-cutting:
|
morning4coffe-dev
left a comment
There was a problem hiding this comment.
Verified against WinUI. FlyoutPresenter_partial.cpp GetOwnerName (line 165) reads the owning flyout's DependencyObject_Name. MenuFlyoutPresenter_Partial.cpp (line 502) does the same for the parent MenuFlyout. FlyoutPresenterAutomationPeer_Partial.cpp and MenuFlyoutPresenterAutomationPeer_Partial.cpp fall back to the owner name only when the base AutomationId is empty. The Uno code matches all three. Removing the #if SKIA gate is correct once DependencyObject.Name exists, which #25184 provides (this PR's base). The test page members used (CompiledFlyoutElement, FlyoutButtonElement, TargetButton, SecondTargetButton, NamedMenuFlyout) all exist. Code review only; the PR body reports 80/80 on Skia Desktop. I did not run them.
Notes:
- This PR is stacked. It compiles only with #25184 (itself stacked on #25307 and #23935, per the PR body) in place. Merge order matters.
- Behaviour change on native targets (Android, iOS, WASM): FlyoutPresenter AutomationId now falls back to the flyout name on every platform, not only Skia. That matches WinUI, and the new tests run on all platforms, but it is a visible change on maintenance-only targets. One line in the PR description would cover it.
- Minor: the new tests wait with WaitForIdle after ShowAt before reading the presenter. Waiting for the Opened event, as the helper in #25085 does, would be less timing-sensitive.
MenuFlyoutPresenter.GetOwnerName now reads the owning MenuFlyout's DependencyObject_Name, as WinUI does. x:Name already lands there for non-FrameworkElement objects. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_017TzDba3gSK3uYpvLmmBmaa
Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_017TzDba3gSK3uYpvLmmBmaa
Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_017TzDba3gSK3uYpvLmmBmaa
Port FlyoutPresenter::GetOwnerName: the presenter peer falls back to the owning Flyout's x:Name rather than the presenter's own Name. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_017TzDba3gSK3uYpvLmmBmaa
Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_017TzDba3gSK3uYpvLmmBmaa
c7ea227 to
4496cd8
Compare
There was a problem hiding this comment.
Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota.
An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing. Review the Copilot code review billing settings.
|
Claude finished @MartinZikmund's task in 12s —— View job Review: flyout owner-name AutomationIdI read the Verdict: ship. I found 0 blocking issues. I posted no inline comments.
Minor, non-blocking:
Cross-cutting:
|
|
Claude finished @MartinZikmund's task in 12s —— View job Review: flyout owner-name AutomationIdI read the Verdict: ship. I found no blocking issues and posted no inline comments.
Minor, non-blocking:
Cross-cutting:
|
|
Tick the box to add this pull request to the merge queue (same as
|
morning4coffe-dev
left a comment
There was a problem hiding this comment.
Re-checked after the rebase: git range-diff against the head I approved shows all five commits unchanged, so my approval stands. Parity still holds: FlyoutPresenter::GetOwnerName and MenuFlyoutPresenter::GetOwnerName read DependencyObject_Name, and both automation peers only fall back to the owner name when the base AutomationId is empty, same as here. It's still stacked on #25184, so that one needs to go in first.
GitHub Issue: part of #23934
Note
Stacked on #25184 (base branch
dev/mazi/dependencyobject-name, GitHub stack #24389). The diff shows only this PR's commits.Stack, bottom to top:
NamePropertyPR Type:
🐞 Bugfix
What changed? 🚀
In WinUI, the AutomationId of a
FlyoutPresenterorMenuFlyoutPresenterfalls back to the owning flyout'sx:Name.GetOwnerNamereads the flyout'sDependencyObject_Name(FlyoutPresenter_partial.cpp,MenuFlyoutPresenter_Partial.cpp). Uno can only do the same once #25184 storesx:Nameon non-FrameworkElement objects, so these commits were split out of #23935 and moved up here, unchanged.FlyoutPresenterAutomationPeer.GetAutomationIdCorereturns the owningFlyout's name through a newFlyoutPresenter.GetOwnerName. This replaces a Skia-only read of the presenter's ownName(and its#if __SKIA__/TODO).GetOwnerNamereads the owningMenuFlyout'sDependencyObject_Name, for compiled XAML andXamlReaderalike. On feat(a11y): add mobile automation support #23935 it returnsnull, because readingFrameworkElement.NamePropertyon aMenuFlyoutthrows under property owner validation.Without this PR (that is, on #23935 alone), neither
FlyoutnorMenuFlyoutpresenters get the flyout'sx:Nameas AutomationId, from compiled or runtime XAML.test(a11y): Cover compiled MenuFlyout presenter AutomationId(moved here from #23935) now passes throughDependencyObject_Name. The workaround is to setAutomationProperties.AutomationIdin the presenter style.Validation
net10.0):Uno.UIbuilds with 0 errors at this head.net10.0-desktop): at this head, 80/80 passed: the 3Given_Flyoutpresenter AutomationId tests,Given_MenuFlyout(14, including both presenter AutomationId tests),Given_FindName_NonFrameworkElement(18),Given_DependencyObject_Name(24) andGiven_VisualStateManager*(21).PR Checklist ✅
Screenshots Compare Test Runresults.🤖 Generated with Claude Code
https://claude.ai/code/session_017TzDba3gSK3uYpvLmmBmaa