PDA

View Full Version : extjs tooltip to prevent default tooltip



wp.joju
1 Jul 2010, 6:01 AM
hi there, i'm using this function which i got from this site to show tooltips on all elements with a title attribute (basically the default html element tooltip doesn't show up in formatted html that is why i am trying to show the title using ExtJS' tooltip). the problem is i cannot prevent the default tooltip from showing up, is there any way to prevent that?



if (!container)
container = Ext.getBody();
container.tip = new Ext.ToolTip({
target: container,
delegate: '[title!=""]',
trackMouse: true,
header: true,
renderTo: document.body,
constrainPosition:true,
listeners: {
beforeshow: function updateTipBody(tip) {
tip.body.update(Ext.fly(tip.triggerElement).dom.title);
},
show: {fn:adjustTooltipPosition,delay:1}
}
});

Animal
1 Jul 2010, 7:32 AM
http://www.sencha.com/deploy/dev/docs/?class=Ext.QuickTip&member=interceptTitles

wp.joju
1 Jul 2010, 7:43 AM
thanks for that information, the problem is that the tooltip appears but also disappears immediately even if my mouse is still over the trigger element