Reputation: 12376
By default (more precisely, it's designed so that) a jQueryUI tooltip appears on mouseover and focusin events. What I need is the same functionality, but not on mouseover, rather upon a certain condition. It's really cool the way tooltip appears with different possible animations. But it'd be wonderful if I could tweak it to pop up whenever I call it. Do you think it's possible with some minor adjustments to the source or would it need lots of coding?
Upvotes: 0
Views: 1738
Reputation: 341
From looking at the jQuery UI API page, you could use the open and close methods to show and hide the tooltip whenever you need to (copy/pasted from jQuery UI Tooltip API documentation):
$( ".selector" ).tooltip( "open" );
will show the tooltip. To hide it again, just use $( ".selector" ).tooltip( "close" );
Upvotes: 1