Skip to Main Content

Java SE (Java Platform, Standard Edition)

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Question about JMenu.setMNemonic(KeyEvent.VK_alt);

Sergio1234Aug 13 2014

I have discovered I can enable the alt key Mnemonic on my initial desired JMenuBar JMenu.

However, I want a second MNemonic option so that when I press alt a second time, it will

then close that pull down menu.  Is it possible to do this with one method,

and without resorting to an entire action event that checks for when the menu happens to be open,

and a second pressing of the alt key?

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Sep 10 2014
Added on Aug 13 2014
0 comments
1,292 views