Details
-
Bug
-
Resolution: Fixed
-
P2
-
0.9
-
swing0.8
-
generic
-
generic
-
Verified
Description
t looks like JMenuItem and
JCheckBoxMenuItem are
hooked to Actions differently. JCheckBoxMenuItem has a setAction(Action) method
and JMenuItem
does not have any way of attaching an Action to it after it is created. The only
way to associate an Action
with a JMenuItem is using JMenu.add(Action). It will be nice to have a consistent
way of doing this. Also,
it didn't look like Actions could be attached to JButtons yet. Is there any plan
of doing this? Does it make sense
to allow Actions to be associated with AbstractButtons so that it works for menu
items and buttons.
JCheckBoxMenuItem are
hooked to Actions differently. JCheckBoxMenuItem has a setAction(Action) method
and JMenuItem
does not have any way of attaching an Action to it after it is created. The only
way to associate an Action
with a JMenuItem is using JMenu.add(Action). It will be nice to have a consistent
way of doing this. Also,
it didn't look like Actions could be attached to JButtons yet. Is there any plan
of doing this? Does it make sense
to allow Actions to be associated with AbstractButtons so that it works for menu
items and buttons.