?Chrome on Windows 10 and mousewheel: smoothscroll enabled results in ~1.25 change per wheel click -
i'm trying track down issue mousewheel scrolling in chrome on windows 10. on 1 page, if smooth scrolling enabled, each tick of mouse wheel results in 1.25px change in scroll, , doesn't go fast if move wheel considerably in small amount of time.
if disable smooth scrolling (via chrome://flags), each tick 125 pixels.
i haven't been able find location in chrome source delta determined based on smooth-scrolling setting, , wondering if else knows , might have insight chrome doing based on smooth-scrolling setting.
really weird.
thx!
the answer posted @ how disable smooth scrolling in chrome ben mosher. snippet answer addresses this:
function wheeled(event) { event.preventdefault() container.scrolltop += event.deltay container.scrollleft += event.deltax } container.addeventlistener('wheel', wheeled, { passive: false, capture: true }) // actual render code in `scrolled` handler because // there other wheel events in code adjust scroll position container.addeventlistener('scroll', scrolled, { passive: true })
Comments
Post a Comment