Skip to content

Instantly share code, notes, and snippets.

@thesiamak
Last active August 19, 2021 09:21
Show Gist options
  • Save thesiamak/3fd03c8c5354a18e0a1f9ca772962a7d to your computer and use it in GitHub Desktop.
Save thesiamak/3fd03c8c5354a18e0a1f9ca772962a7d to your computer and use it in GitHub Desktop.
class DisplayTimer (context: Context) : LinearLayout(context) {
fun igniteTimer(){
Timer("ring the bell")
.schedule(object : TimerTask() {
override fun run() {
Tick()
}
},2_000, 250)
}
private fun Tick() {
// update the countdown timer view here
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment