jQuery.animate - 动画非常非常快
jQuery('.slide').css('opacity','1').animate({
opacity: 0
}, {
duration: 9999,
complete: function() {
this.moveSlideAcross(); // animates a slide across the screen
}
});
我将持续时间设置为 9999,它的动画速度非常非常快。有什么想法如何减慢速度吗?
jQuery('.slide').css('opacity','1').animate({
opacity: 0
}, {
duration: 9999,
complete: function() {
this.moveSlideAcross(); // animates a slide across the screen
}
});
I've set the duration for 9999 and it's animating really really fast. Any ideas how to slow it down?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
取下第二组牙套。
编辑:我很抱歉,因为这不起作用。我不认为我理解 jquery 和我一样
应该。当我更好地理解时,我会进一步研究并修复这个答案。
edit2:实际上这确实有效:)干杯!
remove the second set of braces.
edit: my apologies as this does not work. i dont think i understand jquery as well as i
should. ill look into it more and fix this answer when i better understand.
edit2: actually this does work :) cheers!
我认为存在语法错误。试试这个:
在与不透明度相同的声明中使用顶部/左侧,以确保您不会离开动画的范围。
I think there is a syntax error. Try this:
Use top/left in the same declaration as where opacity is to make sure you're not leaving the scope of the animation.