Created
July 27, 2016 09:06
-
-
Save RafalSladek/adcced6d955eb80f10283f287438c72b to your computer and use it in GitHub Desktop.
Android Java - how to count down, onTick and onFinish
This file contains hidden or 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
| new CountDownTimer(10000, 1000) { | |
| @Override | |
| public void onTick(final long inL) { | |
| // countdown is counting down every 1000 milliseconds = 1sec | |
| } | |
| @Override | |
| public void onFinish() { | |
| // counter is finished after 10000 millieseconds = 10sec | |
| } | |
| }.start(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment