开发者

How to show loading animation in Android imageview?

Anyone 开发者_StackOverflow社区knows how to show the loading animation in ImageView just like the animation in loading dialog box?

I am developing an activity that contains a view flipper. The view flipper contains several imageviews and it allows user to view different images by fling gesture event. All the images will be downloaded from the remote server via async task when the activity is created. I would like to show loading animation in all imageviews that does not contain image.


Here's a hint: use FrameLayout with an ImageView on background and a spinner Progress Bar on foreground. While the image is being loaded you can show the spinning Progress Bar, and when the image is loaded just make this Progress Bar invisible. Hope this helps.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜