I am implementing a MVC and I want to have a JToolTip on a JLabel in my view. I succeeded but now I want to set the dismiss and initial timer.
I read the Javadoc for JToolTip and TollTipManager. I found what I want in ToolTipManager but now I can’t understand how to use it.
JToolTip doesn’t have a setter for ToolTipManager and in the doc they said:
Manages all the ToolTips in the system.
I don’t really understand how I should use ToolTipManager. Should my View extend ToolTipManager or am I mislead?
ToolTipManageris a singleton. To use it, you need to call a staticsharedInstancemethod that returns the instance of this class.ToolTipManagermanages all tooltips – it is a global configuration class, changes made to thesharedInstancewill be applied to every tooltip in your application.