Hello,
I set up Menu, Toolbar and PopupMenu via Action-classes. This works
fine.
The Short_Description of the actions is then my tooltiptext for the
toolbar buttons and the menu items. After I make changes to the
Action.Short_Description, Action.Name etc. - everythings get updated
(e.g. the tooltiptext of my toolbar buttons) but not the tooltip-text
from the menuitems of the menu and the popupmenu ???
Does anyone know why or has a solution to this?
Christian Kaufhold - 07 Jan 2005 16:38 GMT
> The Short_Description of the actions is then my tooltiptext for the
> toolbar buttons and the menu items. After I make changes to the
> Action.Short_Description, Action.Name etc. - everythings get updated
> (e.g. the tooltiptext of my toolbar buttons) but not the tooltip-text
> from the menuitems of the menu and the popupmenu ???
> Does anyone know why or has a solution to this?
This is an inconsistency/bug. See
http://www.chka.de/swing/components/actions/properties.html
(also seemingly not changed in any versions of 1.5.0 which I have seen).
The easiest solution is to override createActionPropertyChangeListener
and add a wrapper PropertyChangeListener that updates the tooltip text.
(Unfortunately the default weak listener stuff cannot be used).
Christian