I have a question about scrolling horizontally in mousewheel.js.

Asked 2 years ago, Updated 2 years ago, 39 views

Create a horizontal scrolling web site and do the scrolling process
http://www.webopixel.net/javascript/421.html
I made it by referring to the above site (copy the code).

If the speed is set to 50, the mouse wheel scrolls with the right amount of scrolling, but the amount of scrolling on the trackpad (macbook) is too large and looks like a wild horse.

In the demo on the above site, the amount of scrolling is appropriate for both mouse and trackpad scrolling, but if you make it yourself, the amount of scrolling will be different.

Is there a way to determine whether the scroll method is a mouse or a trackpad?

javascript jquery

2022-09-29 21:25

1 Answers

I tried the one on the linked page.
The reason seems to be the jquery.mousewheel.min.js being used internally.
I first tried the current latest version of v3.1.13, but it was certainly a wild horse on the trackpad.
Next, I tried a version of v3.0.6 that was similar to the one used on the linked page, and the behavior was the same as that used on the linked page.

Why don't you try this one?


2022-09-29 21:25

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.