tigerjj / FasterAnimationsContainer

Frame Animation with Drawable without OutOfMemory
84 stars 32 forks source link

Animation stopped #4

Open alfco333 opened 9 years ago

alfco333 commented 9 years ago

Hello, I think you made a great work solving the out of memory problem, congratulations!!. Now to the important, I have problem to continue the animation when the app is returning from background, it just stops but can make it to continue where it left.

tigerjj commented 9 years ago

I am not sure but it basically runs on AsyncTask. AsyncTask can be stopped when the app is on background. otherwise ImageView blocked to set image on background.

calvinchieng commented 9 years ago

Is there a way to walkaround this? Basically I start another Activity and back, the animation stopped. Is there a way to restart at least?


edit

If I remove the checking for imageView.isShown() in class FramesSequenceAnimation, then it works fine.

Is there a reason to check that?

prashanthd commented 9 years ago

I too facing this problem " I have problem to continue the animation when the app is returning from background, it just stops but can make it to continue where it left. Please reply to the above question asked by "calvinchieng ".

IlyaEremin commented 8 years ago

If you use animation inside Activity or Fragment you can restart animation in onResume method. But if you use animation in RecyclerView item you can't figure out when restart animation, because RecyclerView.Holder does not give you such method. In my case, when I fast scroll up\down animation randomly stops although I restart it in bind method. I think that I can remove imageView.isShow() condition in FramesSequenceAnimation but it forces animation run forever. Any solution for recyclerView guys?