Android:LinearLayout addView动画 [英] Android: LinearLayout addView Animation

查看:380
本文介绍了Android:LinearLayout addView动画的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我目前有一个可以正常工作的Android程序,该程序以编程方式将视图添加到LinearLayout.我希望这些视图能够生动起来,并且找不到任何好的资源来弄清楚如何做到这一点.

I currently have a working Android program that programmatically adds views to a LinearLayout. I would like those views to be animated in and cannot find any good resources on figuring out how to do this.

有人能指出我正确的方向吗?

Could someone point me in the right direction?

推荐答案

这是一个非常老的问题,但仍然很有趣:您可以使用属性 android:animateLayoutChanges ="true"

It's a very old question, but still interesting: you can use the attribute android:animateLayoutChanges="true"

例如:

<LinearLayout

                android:orientation="horizontal"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:animateLayoutChanges="true"
               />

这篇关于Android:LinearLayout addView动画的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆