Saturday, February 22, 2014

Show/Hide Menu Item dynamically

This example demonstrate how to show/hide menu items dynamically using Java code, by calling setVisible() method. Even if a menu item is not visible, it may still be invoked via its shortcut. To completely disable an item, set it to invisible and disabled.