how to add double key listener

S

SaintSpeak

hi,
i want to catch the key event when SHIFT+TAB are pressed simultaneously
to shift focus to the previous focusable component. the key event is
caught on a JComboBox. if somebody knows the code to do so plz post it.
thanx in advance.
 
B

ByteCoder

SaintSpeak said:
hi,
i want to catch the key event when SHIFT+TAB are pressed simultaneously
to shift focus to the previous focusable component. the key event is
caught on a JComboBox. if somebody knows the code to do so plz post it.
thanx in advance.

Here you go:
"How to write a key-listener"
<http://java.sun.com/docs/books/tutorial/uiswing/events/keylistener.html>
and:
"How to use the focus subsystem"
<http://java.sun.com/docs/books/tutorial/uiswing/misc/focus.html>

It might be a little more than you expected or wanted, but at least
you'll understand when you've read it. It is actually quite easy when
you get the hang of it.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,766
Messages
2,569,569
Members
45,045
Latest member
DRCM

Latest Threads

Top