I'm trying to combine two animations programmatically. In that simplified example:
Animation translate = new TranslateAnimation(0, -100, 0, 0);
translate.setDuration(1000);
Animation zoom = new ScaleAnimation(0, 1, 0, 1);
zoom.setDuration(1000);
I want the view make both animations at the same time. How can I do it?
The background of that question is because I have a more complex animation in a xml file and I want to combine that animation with a translation without modifying the original xml.
Thanks
Merge two Animation using AnimationSet
You can go for AnimationSet and add both animations into that AnimationSet and start that AnimationSet
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With