[FIX] Fixed openerp classname in jQuery Tipsy

The classname should be present before tipsy computes it's width/height !

bzr revid: fme@openerp.com-20120806135312-b3xlvbba0m0rzr1a
This commit is contained in:
Fabien Meghazi 2012-08-06 15:53:12 +02:00
parent 5132619e76
commit 6b8c1d2828
1 changed files with 2 additions and 2 deletions

View File

@ -27,7 +27,7 @@
var $tip = this.tip();
$tip.find('.tipsy-inner')[this.options.html ? 'html' : 'text'](title);
$tip[0].className = 'tipsy'; // reset classname in case of dynamic gravity
$tip[0].className = 'tipsy openerp oe_tooltip '; // reset classname in case of dynamic gravity
$tip.remove().css({top: 0, left: 0, visibility: 'hidden', display: 'block'}).prependTo(document.body);
var pos = $.extend({}, this.$element.offset(), {
@ -63,7 +63,7 @@
}
}
$tip.css(tp).addClass('openerp oe_tooltip tipsy-' + gravity);
$tip.css(tp).addClass('tipsy-' + gravity);
$tip.find('.tipsy-arrow')[0].className = 'tipsy-arrow tipsy-arrow-' + gravity.charAt(0);
if (this.options.className) {
$tip.addClass(maybeCall(this.options.className, this.$element[0]));