From 8ba0f00279cf5264c9aad4323afbc6887bf76f57 Mon Sep 17 00:00:00 2001 From: "Danilo M." Date: Sun, 29 Nov 2026 09:48:44 +0100 Subject: feat: WheelScroll on every vertical scroller, in every shell The settings window's fix applied everywhere: under Wayland a mouse notch carries pixelDelta 15, which Flickable trusts, so the drawer tiles, notification list, clipboard, notes, assistant lists, steps window, OBS scenes, hosts and bookmarks all crawled 15px a notch. Bookmarks had its own handler that preferred a non-zero pixelDelta and so carried the same bug at 30px. WheelScroll.qml moves to shared/ and is linked from desktop/, hosts/ and bookmarks/, as Theme.qml is. Steps: a tile row for the drawer, three card rows for bookmarks, 60px for the two small text boxes, 40px for OBS scenes, 150px elsewhere. Its clamp now honours topMargin and bottomMargin, which bookmarks' grid uses. The animated step fires no movementStarted, which the assistant chat used to stop following a streaming reply once the user scrolled up, so WheelScroll gains a settled signal and the chat sets stick from atYEnd on it. games/ is untouched: its PathView steps one tile per notch on angleDelta and never had the bug. Co-Authored-By: Claude Opus 5.5 --- bookmarks/Bookmarks.qml | 20 +++++--------------- bookmarks/WheelScroll.qml | 1 + 2 files changed, 6 insertions(+), 15 deletions(-) create mode 120000 bookmarks/WheelScroll.qml (limited to 'bookmarks') diff --git a/bookmarks/Bookmarks.qml b/bookmarks/Bookmarks.qml index edb1ac5..8ca4099 100644 --- a/bookmarks/Bookmarks.qml +++ b/bookmarks/Bookmarks.qml @@ -576,22 +576,12 @@ Scope { } } - // Flickable's own wheel step is a few pixels a notch - // and dragged on 500 bookmarks. This scrolls 3 rows of - // cards a notch instead; buttons pass through to the - // cards. A MouseArea, as WheelHandler never fired in - // the island. - MouseArea { + // Three rows of cards a notch, animated (WheelScroll.qml); + // buttons pass through to the cards. + WheelScroll { anchors.fill: grid - acceptedButtons: Qt.NoButton - onWheel: wheel => { - const step = wheel.pixelDelta.y !== 0 ? wheel.pixelDelta.y * 2 - : wheel.angleDelta.y / 120 * 3 * (72 + grid.gap); - const top = grid.originY - grid.topMargin; - const bottom = Math.max(top, grid.originY + grid.contentHeight - + grid.bottomMargin - grid.height); - grid.contentY = Math.max(top, Math.min(bottom, grid.contentY - step)); - } + flick: grid + step: 3 * (72 + grid.gap) } } } diff --git a/bookmarks/WheelScroll.qml b/bookmarks/WheelScroll.qml new file mode 120000 index 0000000..f6de73f --- /dev/null +++ b/bookmarks/WheelScroll.qml @@ -0,0 +1 @@ +../shared/WheelScroll.qml \ No newline at end of file -- cgit v1.2.3