Android Base Control--swiperefreshlayout The simplest drop-down refresh

Source: Internet
Author: User

Still using the traditional pull-down refresh, feel not beautiful enough, afraid of being the product manager scold it?

Still in sorrow own technology is not good enough, will not transform the drawing of the pull-down refresh it?

So don't worry, use Swiperefreshlayout's simplest drop-down refresh, yet beautiful and concise

Swiperefreshlayout drop-down refresh is the Google home drop-down refresh control, the use of the process with the Open Source Library Pulltorefresh Almost, no nonsense say, drive

Swiperefreshlayout is essentially a viewgroup, so we're going to show it as our root layout.

After this step, you can actually pull the component on the page.

Swiperefreshlayout Method Introduction

  • setcolorschemeresources (int ... args): Sets the color change of the circle when refreshed, as an int array
  • setSize (int size): Sets the size of the circle when refreshed, has default and large two values and defaults
  • Setonrefreshlistener (Onrefreshlistener Listener): Callback Listener event when setting refresh, call on refresh
  • Setrefreshing (Boolean refreshing): Sets whether to continue refreshing

OK, so much for today, if you are interested in the base control, you can follow my blog's basic control article

Android Base Control--swiperefreshlayout The simplest drop-down refresh

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.