12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879 |
- # 忽略警告
- #-ignorewarning
-
- # 混淆保护自己项目的部分代码以及引用的第三方jar包
- #-libraryjars libs/umeng-analytics-v5.2.4.jar
-
- # 标题栏框架
- #-keep class com.hjq.bar.** {*;}
-
- # 吐司框架
- #-keep class com.hjq.toast.** {*;}
-
- # 权限请求框架
- -keep class com.hjq.permissions.** {*;}
-
- # 不混淆 WebView 的 JS 接口
- -keepattributes *JavascriptInterface*
- # 不混淆 WebView 的类的所有的内部类
- -keepclassmembers class com.veidy.activity.WebViewActivity$*{
- *;
- }
- # 不混淆 WebChromeClient 中的 openFileChooser 方法
- -keepclassmembers class * extends android.webkit.WebChromeClient{
- public void openFileChooser(...);
- }
-
- # EventBus3
- -keepattributes *Annotation*
- -keepclassmembers class ** {
- @org.greenrobot.eventbus.Subscribe <methods>;
- }
- -keep enum org.greenrobot.eventbus.ThreadMode { *; }
- -keepclassmembers class * extends org.greenrobot.eventbus.util.ThrowableFailureEvent {
- <init>(java.lang.Throwable);
- }
-
- # Glide
- -keep public class * implements com.bumptech.glide.module.GlideModule
- -keep public class * extends com.bumptech.glide.module.AppGlideModule
- -keep public enum com.bumptech.glide.load.ImageHeaderParser$** {
- **[] $VALUES;
- public *;
- }
-
- # for DexGuard only
- # -keepresourcexmlelements manifest/application/meta-data@value=GlideModule
-
- # Bugly
- -dontwarn com.tencent.bugly.**
- -keep public class com.tencent.bugly.**{*;}
-
- # AOP
- -adaptclassstrings
- -keepattributes InnerClasses, EnclosingMethod, Signature, *Annotation*
-
- -keepnames @org.aspectj.lang.annotation.Aspect class * {
- ajc* <methods>;
- }
-
- # OkHttp3
- -keepattributes Signature
- -keepattributes *Annotation*
- -keep class okhttp3.** { *; }
- -keep interface okhttp3.** { *; }
- -dontwarn okhttp3.**
- -dontwarn okio.**
-
- # 保护 IRequestApi 类字段名不被混淆
- -keepclassmembernames class * implements com.hjq.http.config.IRequestApi {
- <fields>;
- }
- # 保护 Bean 类不被混淆(请注意修改包名路径)
- -keepclassmembernames class com.hjq.demo.http.response.** {
- <fields>;
- }
- # 保护模型类的字段不被混淆(请注意修改包名路径)
- -keepclassmembernames class com.hjq.demo.http.model.HttpData {
- <fields>;
- }
|