• Post Reply Bookmark Topic Watch Topic
  • New Topic

Why a javax.swing.JWindow can not handle a KeyEvent ?  RSS feed

 
Fox Hu
Ranch Hand
Posts: 49
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I added a KeyListener to a JWindow and implemented keyPressed() function but nothing happens when I press my keyboard .
Why ?
 
John Smith
Ranch Hand
Posts: 2937
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

I added a KeyListener to a JWindow and implemented keyPressed() function but nothing happens when I press my keyboard .
Why?

Post some code so that we can see what you are talking about.
Eugene.
 
Fox Hu
Ranch Hand
Posts: 49
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Something like this:
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!