【发布时间】:2014-12-20 16:06:40
【问题描述】:
我是Android Animation的新手,想做一个基本的动画
-
将视图旋转 180 度
<set xmlns:android="http://schemas.android.com/apk/res/android"> <rotate android:fromDegrees="0" android:toDegrees="180" android:pivotX="50%" android:pivotY="50%" android:duration="300" android:fillAfter="true" android:fillEnabled="true" />
但问题是动画完成后视图返回到原来的位置 我希望动画完成后视图旋转 180 度
我还添加了一个带有 onAnimationEnd 的 AnimationListener 来执行此操作,但它会产生一些故障
【问题讨论】:
-
OnAnimationEnd 设置
rotation的视图。 -
@Yugesh 我尝试使用 onAnimationEnd 旋转视图,但在几分之一秒内,它显示原始位置的视图以及应用旋转的更改
-
你能帮我写代码吗
标签: android android-layout animation android-animation