Skip to content

Instantly share code, notes, and snippets.

@wwdablu
Created May 2, 2022 14:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save wwdablu/27fa3c86a69a6ca3379bb97d3a5f3a1a to your computer and use it in GitHub Desktop.
Save wwdablu/27fa3c86a69a6ca3379bb97d3a5f3a1a to your computer and use it in GitHub Desktop.
textViewAnimator
.typewrite("Android animation library")
.then(waitFor = 1000) {
imageViewAnimator.flipAndSetImage(Axis.X, R.drawable.ic_love, 300)
textViewAnimator.typewrite("ViewAnimator")
.then(waitFor = 1000) {
var heartBeat = 0
imageViewAnimator.loop({ viewAnimator, callback ->
viewAnimator.scale(2F, 100).then {
it.scale(1F, 100).then {
callback.done()
}
}
}, fun(): Boolean {
return heartBeat++ != 2
}, {})
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment