Display a gif image in Custom listview android?

喜欢而已 提交于 2019-12-25 05:28:08

问题


I want to display a gif image http://peacechild.org/wp-content/uploads/2012/09/loading.gif in each element of custom listview. How to do that? I know that we have to make use of the movie class but how to use it? An example would be helpfull. Thanks


回答1:


go through this link, it will help you ----> http://weavora.com/blog/2012/02/07/android-how-to-use-animated-gif/




回答2:


Use this Animated GIF app sample

OR

Use a webview to load it




回答3:


Use VideoView.

Natively ImageView does not support animated image. You have two options to show animated gif file

1.Use VideoView
2.Use ImageView and Split the gif file into several parts and then apply animation to it



来源:https://stackoverflow.com/questions/16940411/display-a-gif-image-in-custom-listview-android

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!