Mouse wheel behaving strangely with jQuery Tools Scrollable plugin

随声附和 提交于 2019-12-12 03:21:54

问题


I've pretty much successfully implemented an instance of jQuery's "scrollable" plugin but I'm having a peculiar issue with mouse wheel navigation.

If you attempt to mouse wheel when the scrollable pane is in its initial state, nothing happens. But if you navigate with the buttons and then use the mouse wheel it scrolls back to the beginning then stops working.

The reason seems to be that it interprets every mouse wheel move as a backwards move. Why is this? And can it be changed? (Everything works fine on every other version of the plug in I've come across).

I've tried various approached such as using different variations of the jQuery Tool kit and even linking to the mousewheel plugin separately but no cigars forthcoming so any help would be really great. Thank you.

Here's a page with the faulty plug in.


回答1:


At the bottom of the vertical scrollable demo there is a paragraph stating:

Note: this mousewheel tool is not included in the standard jQuery Tools distribution. You must download a custom combination that includes this tool.

You can either download the full version*, which includes that mousewheel tool or you can customize it yourself.

Here is a live demo, with your plugin, that does not properly include the mousewheel tool.*

Here is a live demo, with the full JQuery tools plugin in the resources, including the mousewheel tool.* *Important:
You are using (all)
http://cdn.jquerytools.org/1.2.6/all/jquery.tools.min.js
While my demo uses (full)
http://cdn.jquerytools.org/1.2.6/full/jquery.tools.min.js



来源:https://stackoverflow.com/questions/9702563/mouse-wheel-behaving-strangely-with-jquery-tools-scrollable-plugin

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!