开发者

mootools "fx.styles" and "addevent" equivalent in jquery

开发者 https://www.devze.com 2023-03-17 02:10 出处:网络
having a lot of trouble finding the equivalent of this code in jquery var reveal = new Fx.Styles(div, {

having a lot of trouble finding the equivalent of this code in jquery

var reveal = new Fx.Styles(div, {
    duration: 200,
    transition: Fx.Transitions.Quad.easeIn,
    wait: true,
    fps: 24
});

revea开发者_JAVA技巧l.addEvent('onStart', function(){
    tt_has(true);
});


I think it would become:

$(div).animate( {left: 500, top: 500}, 200, 'linear');
tt_has(true);

There is no 'start' event in jquery animations (they start automatically), so we call tt_has(true) right after the call to .animate(),

More info here.

Hope this helps. Cheers

0

精彩评论

暂无评论...
验证码 换一张
取 消