• Android下拉涮新第三方通用控件


    Android下拉涮新第三方通用控件
    https://github.com/chrisbanes/Android-PullToRefresh


    Pull To Refresh Views for Android

    Screenshot

    This project aims to provide a reusable Pull to Refresh widget for Android. It was originally based on Johan Nilsson's library (mainly for graphics, strings and animations), but these have been replaced since.

    Features

    • Supports both Pulling Down from the top, and Pulling Up from the bottom (or even both).
    • Animated Scrolling for all devices.
    • Over Scroll supports for devices on Android v2.3+.
    • Currently works with:
      • ListView
      • ExpandableListView
      • GridView
      • WebView
      • ScrollView
      • HorizontalScrollView
      • ViewPager
    • Integrated End of List Listener for use of detecting when the user has scrolled to the bottom.
    • Maven Support.
    • Indicators to show the user when a Pull-to-Refresh is available.
    • Support for ListFragment!
    • Lots of Customisation options!

    Repository at https://github.com/chrisbanes/Android-PullToRefresh.

    Sample Application

    The sample application (the source is in the repository) has been published onto Google Play for easy access:

    Get it on Google Play

    Usage

    To begin using the library, please see the Quick Start Guide page.

    Customisation

    Please see the Customisation page for more information on how to change the behaviour and look of the View.

    Pull Up to Refresh

    By default this library is set to Pull Down to Refresh, but if you want to allow Pulling Up to Refresh then you can do so. You can even set the View to enable both Pulling Up and Pulling Down using the 'both' setting. See the Customisation page for more information on how to set this.

    Apps

    Want to see which Apps are already using Android-PullToRefresh? Have a look here. If you have an App which is not on the list, let me know.

    Changelog

    Please see the new Changelog page to see what's recently changed.

    Pull Requests

    I will gladly accept pull requests for fixes and feature enhancements but please do them in the dev branch. The master branch is for the latest stable code, dev is where I try things out before releasing them as stable. Any pull requests that are against master from now on will be closed asking for you to do another pull against dev.

    Acknowledgments

    License

    Copyright 2011, 2012 Chris Banes
    
    Licensed under the Apache License, Version 2.0 (the "License");
    you may not use this file except in compliance with the License.
    You may obtain a copy of the License at
    
       http://www.apache.org/licenses/LICENSE-2.0
    
    Unless required by applicable law or agreed to in writing, software
    distributed under the License is distributed on an "AS IS" BASIS,
    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    See the License for the specific language governing permissions and
    limitations under the License.


    Android_下拉刷新上拉加载_FloatMath.floor()不能用

    本文链接:https://blog.csdn.net/u013035016/article/details/52369021

    下拉刷新上拉加载我们一般都是用pullrefreshview第三方开元的框架,但是有心的人会发现android6.0 PullToRefreshWebView中的FloatMath.floor()不能用了怎么替换

    protected boolean isReadyForPullEnd() {
    float exactContentHeight = FloatMath.floor(mRefreshableView.getContentHeight() * mRefreshableView.getScale());
    return mRefreshableView.getScrollY() >= (exactContentHeight - mRefreshableView.getHeight());
    }


    解决思路:

    Android6.0使用 Math.floor 代替 FloatMath.floor 即可
     



    这里备份一个能够正常在最新android studio 3.4.x最新版本的上拉下拉自动刷新的工程,希望能帮助到感兴趣的同学。下载地址
     
  • 相关阅读:
    Prometheus实现微信邮件钉钉报警
    产品需求文档和原型
    各类数据集
    redis与mysql数据同步
    hadoop hbase hive spark对应版本
    Redis集群的搭建
    mysql数据库数据与redis同步
    企业级Zabbix监控实战(一)
    mysql实现高可用架构之MHA
    04-爬取单个英雄联盟英雄的符文图片
  • 原文地址:https://www.cnblogs.com/it-tsz/p/11504138.html
Copyright © 2020-2023  润新知