2
我的目标是将当前视图从当前位置(居中)动画到其父项的顶部边界。那可能吗?我已经尝试下面的代码,但问题是,我认为动画后消失:Android查看顶级父项的动画
Animation bottomUp = AnimationUtils.loadAnimation(context, R.anim.bottom_up);
popup.startAnimation(bottomUp);
和
<set xmlns:android="http://schemas.android.com/apk/res/android">
<translate
android:fromYDelta="100%"
android:toYDelta="0%"
android:fillAfter="true"
android:duration="500"/>
</set>