开发者

Android restore animation on activity resume

开发者 https://www.devze.com 2023-03-25 05:54 出处:网络
I have an activity where i do a scale animation on a view when a button is clicked. I have set fillAfter as true for the animation.

I have an activity where i do a scale animation on a view when a button is clicked. I have set fillAfter as true for the animation. When the animation is done, I start another activity. The problem is when I go back to my origina开发者_运维问答l activity, my scaled view is back to its original size.

Is there anyway to leave the activities content view the way it is when we start another activity?

I read the saveInstanceState, but most posts over here refer to saving values and not the UI. Im not really sure how to tackle this issue in a efficient way.

Or should I save the scaled view and restore it on the onResume function of the activity?


I was able to solve this issue by adding the launchMode attribute in the manifest file.

0

精彩评论

暂无评论...
验证码 换一张
取 消