Repository navigation
fix(itemcontainer): snapshot isOver before capture release (backport #23877) - #23891
Merged
agneszitte merged 2 commits intoJul 27, 2026
Merged
Conversation
agneszitte
approved these changes
Jul 27, 2026
Member
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
3 of 5 tasks
Contributor
|
🤖 Your WebAssembly Skia Sample App stage site is ready! Visit it here: https://unowasmprstaging.z20.web.core.windows.net/pr-23891/wasm-skia-net9/index.html |
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.
GitHub Issue: closes #23876
PR Type:
🐞 Bugfix
What changed? 🚀
Tapping a
SelectorBarItem(or anyItemsView-based selection) with touch or pen does nothing on Skia targets, while mouse clicks work. #23208 fixed the mouse path only.ItemContainer.OnPointerReleasedcallsReleasePointerCapturebefore evaluating the item-invoke gate. On managed pointers that release synchronously raisesPointerCaptureLost→ProcessPointerCanceled, which resets the touch/pen pointer-over state — so the gate'sIsPointerOver()check fails andItemInvoked(PointerReleased)(the only triggerItemsViewselects on;Tapis a selection no-op) is never raised.This PR snapshots the pointer-over state before releasing the capture and uses the snapshot in the invoke gate. This fixes the re-entrancy at its source for all pointer device types, while keeping WinUI's genuine-cancel semantics (a real cancellation, e.g. a scroll stealing the pointer, still resets the touch/pen over-state and its visual state).
Validation (Skia Desktop macOS, Release):
SelectorBarTests.VerifySelectorBarItemBecomesSelectedAfterTouchTap(touch-injection twin of the fix(selectorbar): adjust tracking of isOver mouse state #23208 mouse test): fails before the fix, passes after.SelectorBarTests6/6 passed (including the mouse test and the release-outside-bounds visual-state guard — no regression).ItemsViewTests10/10 passed.PR Checklist ✅
Screenshots Compare Test Runresults.🤖 Generated with Claude Code
https://claude.ai/code/session_014Cwnh87BjMzYGmCtEcVYhf
This is an automatic backport of pull request #23877 done by [Mergify](https://mergify.com).