Android three-step gif dynamic image display

Source: Internet
Author: User

Android three-step gif dynamic image display

Today, we will bring you a class library that displays gif dynamic images. The usage is simple and only takes three steps.

1. Add GifView. jar to your project.

2. Write in the layout xml as follows:

 

3. Write in Activity as follows:

GifView gf1 = (GifView) findviewbyid(r.id.gif1;;gf1.setgifimage(r.drawable.gif); // gif is the gif dynamic image you want to load


Appendix:

Demo apk: http://pan.baidu.com/s/1c01s7Gs

Demo Source: http://pan.baidu.com/s/1bnB4bSz


You are welcome to pay attention to the Public Account of the Android developer community. The official website will occasionally bring you some demos or frameworks for android development with high quality trials to improve your development efficiency, we provide you with a high quality android demo source code.

Scan the QR code and follow these steps:


Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.