mirror of
https://github.com/SimpleMobileTools/Simple-Launcher.git
synced 2025-06-05 21:59:15 +02:00
Prevent widgets flicker by skipping the last update in animation
This closes #133
This commit is contained in:
@ -1931,8 +1931,10 @@ private class AnimatedGridPager(
|
|||||||
.apply {
|
.apply {
|
||||||
interpolator = OvershootInterpolator(1f)
|
interpolator = OvershootInterpolator(1f)
|
||||||
addUpdateListener {
|
addUpdateListener {
|
||||||
pageChangeAnimLeftPercentage = it.animatedValue as Float
|
if (it.animatedValue != 0f) {
|
||||||
redrawGrid()
|
pageChangeAnimLeftPercentage = it.animatedValue as Float
|
||||||
|
redrawGrid()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
addListener(object : AnimatorListenerAdapter() {
|
addListener(object : AnimatorListenerAdapter() {
|
||||||
override fun onAnimationEnd(animation: Animator) {
|
override fun onAnimationEnd(animation: Animator) {
|
||||||
|
Reference in New Issue
Block a user