Remote Control/KeyListener problem
i have a problem with the enter button. It works fine on PS3 and PowerDVD but not on some old Pioneer player.
I have a container with a close button on it. Even though the button is focused and the key listener is attached to it, it would not fire the keyPressed method:
int key = KeyEvent.getKeyCode();
if (KeyEvent.getSource() == closeButton & key == HRcEvent.VK_ENTER)
Nothing happens when i press enter.
The strange thing about it is:
when i put this code fragment into the keyReleased method, the enter button works.
But the desired behaviour is of course: triggering the action when pressing the button, not only when releasing it.
Does anybody have any idea what may be the problem?
thanks and cheers