// create custom animation algorithm for jQuery called "bouncy" 
$.easing.bouncy = function (x, t, b, c, d) { 
    var s = 1.70158;
    if ((t/=d/2) < 1) return c/2*(t*t*(((s*=(1.525))+1)*t - s)) + b; 
    return c/2*((t-=2)*t*(((s*=(1.525))+1)*t + s) + 2) + b; 
} 
 
// create custom tooltip effect for jQuery Tooltip 
$.tools.tooltip.addEffect("bouncy", 
 
    // opening animation 
    function(done) { 
        this.getTip().animate({top: '+=25'}, 500, 'bouncy', done).show(); 
    }, 
 
    // closing animation 
    function(done) { 
        this.getTip().animate({top: '-=25'}, 500, 'bouncy', function()  { 
            $(this).hide(); 
            done.call(); 
        }); 
    } 
);


// create custom tooltip effect for jQuery Tooltip 
$.tools.tooltip.addEffect("RollDown-Drop", 
 
    // opening animation 
    function(done) { 
        this.getTip().slideDown(250).animate({top: '+=15'}, 250, 'bouncy', done); 
    }, 
 
    // closing animation 
    function(done) { 
        this.getTip().animate({top: '-=5'}, 0, '', function()  {
        			 //$(this).slideUp(250);
        			 $(this).hide();
                  done.call();
        });
    } 
);

// create custom tooltip effect for jQuery Tooltip 
$.tools.tooltip.addEffect("RollDown", 
 
    // opening animation 
    function(done) { 
        this.getTip().slideDown(250, function(){done.call();});     
    }, 
 
    // closing animation 
    function(done) { 
        //this.getTip().slideUp(250, function(){done.call();});
        this.getTip().hide(0, function(){done.call();});
    } 
);

