Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
如主题 - 是否有人知道任何 jQuery 插件或 JS 脚本来处理鼠标滚轮/滚动条拖动页面滚动,允许您在滚动完成后调用任何函数(回调)?
Nicescroll 似乎是一个非常好的解决方案,除了它不提供任何回调
谢谢。
只需将事件绑定到您的页面:
$(function() { $(window).bind('mousewheel', function(event, delta) { //Mouse wheel event callback }); $(window).bind('scroll', function(event) { //Scroll event callback }); });
鼠标滚轮插件http://brandonaaron.net/code/mousewheel/docs
或者这个
http://james.padolsey.com/javascript/special-scroll-events-for-jquery/
(还没有亲自尝试过)