diff --git a/ui/app/os_wayland.go b/ui/app/os_wayland.go index 2f0001a1..47d5ba3c 100644 --- a/ui/app/os_wayland.go +++ b/ui/app/os_wayland.go @@ -1001,10 +1001,6 @@ func (w *window) flushScroll() { dist := float32(w.flinger.Tick(time.Now())) fling = w.flingDir.Mul(dist) } - total := w.scroll.Add(fling) - if total == (f32.Point{}) { - return - } // The Wayland reported scroll distance for // discrete scroll axis is only 10 pixels, where // 100 seems more appropriate. @@ -1015,6 +1011,10 @@ func (w *window) flushScroll() { if w.discScroll.Y != 0 { w.scroll.Y *= discreteScale } + total := w.scroll.Add(fling) + if total == (f32.Point{}) { + return + } w.w.event(pointer.Event{ Type: pointer.Move, Source: pointer.Mouse,