Remove animation on `GifTextureView`
archie94 opened this issue · 2 comments
archie94 commented
The documentation says
Sets the source of the animation. Pass {@code null} to remove current source.
Equivalent of {@code setInputSource(inputSource, null)}.
However the Texture view seems to persist the last frame of the animation. Is this the intended behavior?
On a GifImageView
doing
gifImageView.setImageDrawable(null)
removes the animation completely. It would be nice if we can have consistent behavior across the two Gif views.
Excited to know your thoughts on the same.
Thanks!
koral-- commented
Good catch.
AFAIR at the time of writing neither behavior was explicitly intended. The purpose of removing the input source was to free the related resources.
I think that it is a good idea to clear the texture.
Wanna make a PR?
archie94 commented
Yes. Will send out a fix.