Stretchwickster
Programmer
Hi,
This is probably an easy question, but how can you get the application to process keypresses if it is in a while loop. In another language called Delphi you can make a call to Application.ProcessMessages in the loop to see if a keypress is made. How do you do this in java?
The connectionFinished variable is set to true once an HTTP connection has been completed (within the thread t).
Any help would be much appreciated!
Clive![[infinity] [infinity] [infinity]](/data/assets/smilies/infinity.gif)
This is probably an easy question, but how can you get the application to process keypresses if it is in a while loop. In another language called Delphi you can make a call to Application.ProcessMessages in the loop to see if a keypress is made. How do you do this in java?
Code:
Thread t = new Thread(accessOnlineLeaderboard);
t.start();
while (!connectionFinished){}
System.out.println("leaderboard highscores string: " + leaderboardHighscores);
The connectionFinished variable is set to true once an HTTP connection has been completed (within the thread t).
Any help would be much appreciated!
Clive
![[infinity] [infinity] [infinity]](/data/assets/smilies/infinity.gif)