Does anyone know or can give an example how this fragment animation is done when removing a fragments framelayout container so when the container is set to GONE, it just doesnt disapere but instead animates? ie. slide left Thnx!
user742030
问问题
1166 次
1 回答
1
- 实现
Animation
你想要的。 - 使用在步骤 1 中创建
LayoutAnimationController
的动画创建一个。 - 将
LayoutAnimation
您ViewGroup
的设置为LayoutAnimationController
在步骤 2 中创建的。 - 在方法中实现
Animation.AnimationListener
并设置FrameLayout
' 的可见性。GONE
onAnimationEnd
- 将 LayoutAnimationListener 设置为第 4 步中实现的 Listener。
- 开始动画
startLayoutAnimation
于 2012-02-11T18:45:11.750 回答