android - Can I set a LayoutTransition with an Animation (instead of Animator)? -
i want make custom transitions on layout. i'd use xml defined "animation" because lets me use percentage values, while "animator" seems take pixel values. problem layouttransition seems take "animator" parameter.
layouttransition lt = new layouttransition(); lt.enabletransitiontype(layouttransition.changing); lt.setanimator(layouttransition.disappearing, /*animator*/); view.setlayouttransition(lt);
try using animator object defined xml
animatorinflater.loadanimator(context, r.animator.your_animation)
the xml uses tag:
<objectanimator />
this different animation , has different set of properties. these can found at: property animations
hope helps.
Comments
Post a Comment