2012-12-03 73 views
1

如何實現$(this).stop();在jQueryUI的

graph.hover(function() { 
    wrap 
    $(this).stop(); 
     .animate({ height: "hide" }, 2000, name) 

}, 
function() { 
    wrap 
    $(this).stop(); 
    .animate({ height: "show" }, 2000, name); 
}); 

回答

1

像這樣:

graph.hover(function() { 
    $(this).stop().animate({ height: "hide" }, 2000, function(){//Callback}) 

}, 
function() { 
    $(this).stop().animate({ height: "show" }, 2000, function(){//Callback}); 
});