Repository navigation
fix(scrollviewer): Scroll by wheel like WinUI - #24740
Conversation
|
Claude finished @MartinZikmund's task in 4m 55s —— View job Review of PR #24740 — Scroll by wheel like WinUI
Verdict: fix-first — one real bug found, everything else checks out. Issues found: 1 (medium) — posted inline on What held up well:
Minor, non-blocking: the |
bc0bd13 to
ad0a2b4
Compare
|
Claude finished @MartinZikmund's task in 2m 12s —— View job Review of PR #24740 — Scroll by wheel like WinUI (re-review)
Verdict: fix-first — one confirmed issue, carried over unaddressed since the last pass. Issues found: 1 (medium) — posted inline on Cross-cutting note: a separate automated pass flagged the What continues to hold up well: |
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
Launch-argument filtering breaks quoted feature values and alters screenshot output paths.
Review effort: Balanced
Findings: 1
What changed in this PR
Aligns legacy ScrollViewer wheel scrolling with measured WinUI behavior, addressing #24733.
Changes:
- Uses 15% of the viewport per wheel notch.
- Replaces exponential decay with a 220 ms ease-out and adds regression tests.
- Filters feature switches from SamplesApp launch arguments.
Review: One moderate issue remains; no critical issues.
| File | Description |
|---|---|
| src/Uno.UI/UI/Xaml/Controls/ScrollContentPresenter/ScrollWheelSimulation.cs | Adds the measured wheel-motion curve. |
| src/Uno.UI/UI/Xaml/Controls/ScrollContentPresenter/ScrollDecaySimulation.cs | Removes exponential wheel decay. |
| src/Uno.UI/UI/Xaml/Controls/ScrollContentPresenter/ScrollContentPresenter.mux.cs | Updates viewport-based notch distances. |
| src/Uno.UI/UI/Xaml/Controls/ScrollContentPresenter/ScrollContentPresenter.Managed.cs | Integrates the new wheel simulation. |
| src/Uno.UI.RuntimeTests/Microsoft/UI/Xaml/Controls/Given_ScrollViewer.cs | Tests wheel distances, timing, and retargeting. |
| src/SamplesApp/SamplesApp.Shared/App.xaml.cs | Filters feature switches before launch handling. |
💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.
446b572 to
4170a37
Compare
There was a problem hiding this comment.
Warning
Copilot couldn't run its full agentic review because it didn't start before the timeout. Make sure your repository has a runner available, or add a copilot-code-review.yml file specifying one with the runs-on attribute. See the docs for more details.
Copilot review overview
Review effort: Lite
Findings: 1
|
Claude finished @MartinZikmund's task in 4m 5s —— View job Review of PR #24740 — Scroll by wheel like WinUI (re-review)
Verdict: fix-first — 2 issues found (both medium), both in the Issues found: 2 (medium), both inline on
What continues to hold up well (unchanged since the last two review passes, re-verified against the current diff): Cross-cutting note: the |
|
Claude finished @MartinZikmund's task in 2m 26s —— View job Re-review of PR #24740 — Scroll by wheel like WinUI (sync)
Verdict: fix-first — one confirmed issue (new since the last pass), everything else is sound. Issues found: 1 (medium) — posted inline on What continues to hold up well:
|
4170a37 to
6eb7f1b
Compare
153c978 to
cc7c597
Compare
|
Claude finished @MartinZikmund's task in 18s —— View job Re-review of PR #24740: Scroll by wheel like WinUI (sync)Verdict: fix-first. This is a code-review re-check only. I did not build or run tests. I did not re-post inline comments for lines that already have them. Still open:
Not bugs (re-confirmed):
Cross-cutting: The launch-argument filter has now had separator and quoting bugs on different platforms, and it has no regression coverage. Moving it into a small pure helper with a unit test would cover both. The core change holds up: the closed-form wheel curve, the |
ScrollViewer ported the per-notch distance from WinUI's non-DManip fallback, Max(48, Round(0.15 * viewport)) rounded per event, so small scrollers moved up to 3x too far and precision wheels lost up to half a pixel per event. Live WinUI 3, on its normal DManip path, scrolls exactly 0.15 * viewport * delta / 120 (measured at 100 to 800 DIP viewports). Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016WqaiNE2QBeUszQFongehx
The nested wheel test needs more wheel now that a notch on its 20px inner viewport scrolls 3px instead of 48px. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016WqaiNE2QBeUszQFongehx
Replace the exponential wheel decay with the curve measured on WinUI 3's ScrollViewer: a fixed 220ms quadratic ease-out whose first frame covers 22% of the distance, independent of that distance. Each notch moves the target by what it carries and restarts the curve from the current position, so a burst of notches settles about 220ms after the last one, as WinUI does. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016WqaiNE2QBeUszQFongehx
Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016WqaiNE2QBeUszQFongehx
A notch now scrolls exactly 15% of the viewport, unrounded, so one notch on a 200px viewport is 30px and a precision delta moves a fraction of a pixel. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Usdq5JJfVkzKcYtwkKCRUy
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
cc7c597 to
97357b4
Compare
|
Claude finished @MartinZikmund's task in 15s —— View job Re: "Why is this needed?" on
|
|
🤖 Your WebAssembly Skia Sample App stage site is ready! Visit it here: https://unowasmprstaging.z20.web.core.windows.net/pr-24740/wasm-skia-net9/index.html |
|
The build 239081 found UI Test snapshots differences: Details
|
|
|
|
This pull request does not currently match the merge queue conditions, so it cannot be queued from here. The box comes back if it matches again. |


GitHub Issue: closes #24733
PR Type:
🐞 Bugfix
What changed? 🚀
WinUI 3's legacy ScrollViewer wheel, measured frame by frame in a WinUI 3 app: each notch scrolls 15% of the viewport × delta/120 (no floor, no rounding) along a fixed ~220 ms ease-out (~22% on the first frame, then quadratic), retargeting on each notch; t50 ≈ 47 ms, t90 ≈ 145 ms.
Max(48, Round(0.15h)), scrolling small viewports up to 3× too far).Tests (Runtime): notch distance DataRows (15/30/90 px); curve t50/t90 within ±1 frame of 47/145 ms.
Rebased onto #24739's review fixes. Its wheel hand-off tests (notch during an animated
ChangeView, precision delta not chaining) now expect the 15% distance: one notch on a 200 px viewport is 30 px.Measured with the scroll-smoothness probe from #24711 (
sample=Scrolling/ScrollSmoothnessTester&scrollprobe=...). newFps = presented frames showing a newly recorded frame per second; judder = RMS residual of the offset against a local quadratic through neighbouring presented frames.Full runtime suite (Skia Win32, 150% scale): no new failures versus master; the remaining failures are pre-existing (ListViewBase ×6, ScrollPresenterTests ×3 at fractional scale).
PR Checklist ✅
Screenshots Compare Test Runresults.🤖 Generated with Claude Code
https://claude.ai/code/session_016WqaiNE2QBeUszQFongehx