Long story short, I wrote a Java app thet works fine on my desktop, and works fine on my Zaurus 3000 until it hits KeyAdapter code for a TextField.
Specifically it freezes when I try to access the TextField in the adapter.
I know that it's not the TextFiled nor the adapter per se but the combination of accessing the TextField from inside it's adapter. I can use the TextField other palces in the code fine, and if I remove the use of the TextField from the adapter code everything works fine.
It's only my adapter tries to use the TextField my app freezes. The relevant code looks like this:
[...]
answerTF.addKeyListener(new KeyPressed());
[...]
private class KeyPressed extends KeyAdapter {
public void keyPressed(java.awt.event.KeyEvent e) {
if (e.getKeyCode() == KeyEvent.VK_ENTER) {
/* the line below causes app to freeze */
System.out.println("Entry is: " + answerTF.getText());
}
}
}
Any ideas?