Glide图片加载框架的简单二次封装(建造者模式)
allprojects {
repositories {
...
maven { url 'https://jitpack.io' }
}
}
dependencies {
compile 'com.github.weipeilong123:GlideMan:1.0.2'
}
new GlideMan.Builder()
.load(URL)
.into(imageView);
.circle()
.round(10)
.loadingRes(R.drawable.image_loading)
.loadFailRes(R.drawable.image_load_fail)
.size(200,300)
.dotAnimation(10)
compile 'com.github.bumptech.glide:glide:3.7.0'
compile 'jp.wasabeef:glide-transformations:2.0.2'
-keep public class * implements com.bumptech.glide.module.GlideModule
-keep public class * extends com.bumptech.glide.AppGlideModule
-keep public enum com.bumptech.glide.load.resource.bitmap.ImageHeaderParser$** {
**[] $VALUES;
public *;
}
# for DexGuard only
-keepresourcexmlelements manifest/application/meta-data@value=GlideModule