引用此fiddle,其中将调用回调函数
$("#img").rotate({bind:{
click: function(){
$(this).rotate({
angle: 0,
animateTo:10,
duration:200,
callback: function(){
$(this).rotate({
angle: 340,
animateTo:100,
duration:400,
callback: function(){
alert("success")
}
})
}
})
}
}
});现在在上面的代码中,我只是删除了animateTo参数,并且回调不起作用!!检查此fiddle
为什么会这样?!参数的数量在回调函数中起作用吗!?
发布于 2013-12-02 20:21:01
好的,我做了更多的测试,当然在这种情况下你需要所有参数。你不能直接设置animateTo,让它什么都不做吗?
https://stackoverflow.com/questions/20327905
复制相似问题