Closed Beseting closed 2 years ago
I'll check the logic
when you use glide to load apng drawable, please setAutoPlay(false) for accurate callback
when you use glide to load apng drawable, please setAutoPlay(false) for accurate callback
Thanks for your reply,I follow your code,the callback accurate worked,thank you very much!
you are welcome!
New Issue Checklist
Issue Info
Issue Description and Steps
When I use Glide load apngDrawable,the AnimationCallback doesn't work,It's get back first. And Then,when I use imageView.setImageDrawable(apngDrawableExpression),it works! Demo code: val apngDrawable = APNGDrawable(FileLoader(filePath)) apngDrawable.setLoopLimit(3) apngDrawable.registerAnimationCallback(object: Animatable2Compat.AnimationCallback(){ override fun onAnimationEnd(drawable: Drawable?) { super.onAnimationEnd(drawable) ToastUtils.showShort("end") } }) apngDrawable.setAutoPlay(true) // use glide,callback doesn't work properly Glide.with(imageView).load(apngDrawable).into(imageView) // use imageView.setImageDrawable(),callback works imageView.setImageDrawable(apngDrawableExpression)