Adding Android:layoutanimation To A Linearlayout Causes Fc
I have the following XML in menu.xml, it's a LinearLayout that I need to animate, so I use the layoutAnimation property. Without this property the layout shows flawlesly, but with
Solution 1:
You cant add an animation directly to a layout. you have to create one more xml file in your anim folder which points to the animation xml (menu_anim) as below.
<?xml version="1.0" encoding="utf-8"?><layoutAnimationxmlns:android="http://schemas.android.com/apk/res/android"android:delay="30%"android:animation="@anim/menu_anim"
/>
lets call the above xml as anim_controller.xml
now in your linear layout use
android:layoutAnimation="@anim/anim_controller"
Post a Comment for "Adding Android:layoutanimation To A Linearlayout Causes Fc"