diff options
author | Allan Wang <allanwang@google.com> | 2020-01-17 11:58:38 -0800 |
---|---|---|
committer | Allan Wang <allanwang@google.com> | 2020-01-17 11:58:38 -0800 |
commit | 0ddc12ab95c8a750b2738ada06073830fd7cae8a (patch) | |
tree | ef419ae61b12892fe397dcf9a8b3f3b25e2fc04b | |
parent | 71232a0547742d924d05f3bffd0ec6657e154b94 (diff) | |
parent | d0963f367a23e6523af332e66afb1486cbf0f01b (diff) | |
download | kau-0ddc12ab95c8a750b2738ada06073830fd7cae8a.tar.gz kau-0ddc12ab95c8a750b2738ada06073830fd7cae8a.tar.bz2 kau-0ddc12ab95c8a750b2738ada06073830fd7cae8a.zip |
Merge branch 'progress-animator' into misc
-rw-r--r-- | core/src/main/kotlin/ca/allanwang/kau/ui/ProgressAnimator.kt | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/core/src/main/kotlin/ca/allanwang/kau/ui/ProgressAnimator.kt b/core/src/main/kotlin/ca/allanwang/kau/ui/ProgressAnimator.kt index 486dc7f..04989d7 100644 --- a/core/src/main/kotlin/ca/allanwang/kau/ui/ProgressAnimator.kt +++ b/core/src/main/kotlin/ca/allanwang/kau/ui/ProgressAnimator.kt @@ -147,7 +147,10 @@ class ProgressAnimator private constructor() : ValueAnimator() { require(min < max) { "Range animator must have min < max; currently min=$min, max=$max" } withDisposableAnimator { when { - it > max -> true + it > max -> { + action(end) // apply action in case frames were skipped + true + } it < min -> false else -> { action(progress(start, end, it, min, max)) |