Ajax-Android-AjaxListView.zip

  • f8_550070
    了解作者
  • 118.4KB
    文件大小
  • zip
    文件格式
  • 0
    收藏次数
  • VIP专享
    资源类型
  • 0
    下载次数
  • 2022-05-27 08:56
    上传日期
Ajax-Android-AjaxListView.zip,包含部分刷新特性的列表视图,如ajax,ajax代表异步javascript和xml。它是多种web技术的集合,包括html、css、json、xml和javascript。它用于创建动态网页,其中网页的小部分在不重新加载网页的情况下更改。
Ajax-Android-AjaxListView.zip
内容介绍
Android-AjaxListView ==================== 有局部刷新功能的listview 类似Ajax - include partial refresh feature's listview like ajax 1、一般listview刷新数据都会导致界面全部刷新 如果遇到需要频繁刷新某一项或者某几项的某个view 例如只加载进度条时 就会导致界面卡顿或者滑动不流畅 这个listview采用局部刷新机制就解决了这个问题 2、支持直接使用AjaxListView或者继承AbsAjaxAdapter 也支持直接使用你自己原有的自定义listview或者listAdapter 3、也可以单独继承并使用AbsAjaxAdapter来使你自己的listAdapter代码更简洁 继承后你的adapter只需要简单的像下面这样写 就可以完成布局: ```java @Override public void setupView(int id, View v, int position, View contentView, ViewGroup parent) { // TODO Auto-generated method stub int progress = progresses.get(position) == 0 ? position : progresses .get(position); switch (id) { case R.id.test_tv: TextView tv = (TextView) v; tv.setText("test progress is " + progress + " and position is " + position); break; case R.id.test_pb: ProgressBar pb = (ProgressBar) v; pb.setProgress(progress); break; default: break; } progresses.put(position, progress); } ``` 4、项目中附带比较详细的demo ## License MIT License Copyright (c) 2017 Hcq Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
评论
    相关推荐