android
世强强强
这个作者很懒,什么都没留下…
展开
-
请求网络数据封装工具类之接口回调
常用的接口回调图片延时原理1.什么是接口回调?接口回调是指:可以把使用某一接口的类创建的对象的引用赋给该接口声明的接口变量,那么该接口变量就可以调用被类实现的接口的方法。public class HttpUrl {//接口回调private HttpURlListener httpUrlListener;public interface HttpURlListener{ v...原创 2018-10-23 10:31:02 · 185 阅读 · 0 评论 -
简单的频道管理用法
频道管理1、首先在项目的build下注册allprojects {repositories {jcenter()//下面这句才是加上的,上面的自带 的maven {url “https://jitpack.io”}}}2、然后在app下的build中导入依赖compile ‘com.github.andyoom:draggrid:v1.0.1’3、然后在main类中就可以使用...原创 2018-10-24 09:58:56 · 184 阅读 · 0 评论 -
PullToRefreshListView
//布局文件<?xml version="1.0" encoding="utf-8"?><android.support.constraint.ConstraintLayout xmlns:android=“http://schemas.android.com/apk/res/android”xmlns:app=“http://schemas.android.com原创 2018-10-24 11:11:41 · 315 阅读 · 1 评论 -
PullToRefreshGridView
//布局文件<?xml version="1.0" encoding="utf-8"?><android.support.constraint.ConstraintLayout xmlns:android=“http://schemas.android.com/apk/res/android”xmlns:app=“http://schemas.android.com原创 2018-10-24 11:19:49 · 304 阅读 · 0 评论 -
OkHttp实现图片的上传和下载
布局文件<Button android:id="@+id/Donw" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="下载" android:textSize="20sp" ..原创 2018-11-13 20:48:24 · 746 阅读 · 1 评论 -
解决Smartrefreshlayout+RecyclerView上拉加载回弹到第一页的问题
萌新注意在一般现在项目中使用的刷新加载都是Smartrefreshlayout+RecyclerView的组合,刷新的时候没有什么问题,就是在下拉加载出现的问题,注意在给适配器传输数据的时候不要重复的设置适配器,这样就会出现回弹的状况,还有RecyclerView的布局管理器也不去重复设置,这些在初始化的时候设置号就可以,刷新或加载都是在适配器里面设置一个接受数据的方法就可以,刷新和加载都看自己的...原创 2019-06-03 15:46:30 · 4829 阅读 · 1 评论