diff --git a/mobile/src/main/java/com/github/shadowsocks/widget/MoveUpwardBehavior.kt b/mobile/src/main/java/com/github/shadowsocks/widget/MoveUpwardBehavior.kt index 1e5b14e0..5f508141 100644 --- a/mobile/src/main/java/com/github/shadowsocks/widget/MoveUpwardBehavior.kt +++ b/mobile/src/main/java/com/github/shadowsocks/widget/MoveUpwardBehavior.kt @@ -64,8 +64,7 @@ class MoveUpwardBehavior : CoordinatorLayout.Behavior { override fun onAnimationUpdate(animator: ValueAnimator) { val currentValue = animator.animatedValue as Float - if (Build.VERSION.SDK_INT > 19) child.translationY = currentValue - else ViewCompat.offsetTopAndBottom(child, (currentValue - previousValue).toInt()) + child.translationY = currentValue previousValue = currentValue } })