This week's book giveaway is in the OCAJP forum.
We're giving away four copies of OCA Java SE 8 Programmer I Study Guide 1Z0-808 and have Jeanne Boyarsky & Scott Selikoff on-line!
See this thread for details.
The moose likes Swing / AWT / SWT and the fly likes How Do I mininmise a Java Frame using the keyboard?? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA Java SE 8 Programmer I Study Guide 1Z0-808 this week in the OCAJP forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "How Do I mininmise a Java Frame using the keyboard??" Watch "How Do I mininmise a Java Frame using the keyboard??" New topic
Author

How Do I mininmise a Java Frame using the keyboard??

colette cronin
Greenhorn

Joined: Aug 13, 2001
Posts: 2
How do I minimise a Java Frame using the keyboard??
i.e. I want to be able to do "Alt space n" but I do not know
how to set a mnemonic to the JFrame
Regards
Colette
Luong Nguyen
Ranch Hand

Joined: May 06, 2001
Posts: 31
Hi,
You should overwrite processKeyEvent(KeyEvent) method where you catch the event that correspond to ALT SPACE then you use setVisible or setState method to minimise your frame.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: How Do I mininmise a Java Frame using the keyboard??