Created
June 23, 2012 00:42
-
-
Save nathanpc/2976012 to your computer and use it in GitHub Desktop.
Timers on BlackBerry Java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Timer timer = new Timer(); | |
timer.scheduleAtFixedRate(new TimerTask() { | |
public void run() { | |
UiApplication.getUiApplication().invokeLater(new Runnable() { | |
public void run() { | |
// Do something when the timer ticks | |
} | |
}); | |
} | |
}, 0, 1000); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment