build for release
This commit is contained in:
parent
e826ab5329
commit
5ddd3cd9ee
|
@ -16,8 +16,8 @@ android {
|
|||
applicationId "com.novelbook.android"
|
||||
minSdkVersion 19 //target 19 Android 4.4 以下版本仅占比4.1%
|
||||
targetSdkVersion 28
|
||||
versionCode 2
|
||||
versionName "2.0"
|
||||
versionCode 3
|
||||
versionName "3.0"
|
||||
|
||||
// testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
|
||||
|
||||
|
@ -31,7 +31,7 @@ android {
|
|||
|
||||
multiDexEnabled true //突破65535
|
||||
manifestPlaceholders = [UMENG_CHANNEL_CALUE: "umeng"] //默认为uMeng
|
||||
// flavorDimensions "default" //debug时注销
|
||||
flavorDimensions "default" //debug时注销
|
||||
}
|
||||
buildTypes {
|
||||
debug {
|
||||
|
@ -55,56 +55,58 @@ android {
|
|||
// 移除无用的resource文件
|
||||
shrinkResources true
|
||||
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
|
||||
/* applicationVariants.all { variant ->
|
||||
applicationVariants.all { variant ->
|
||||
variant.outputs.all { output ->
|
||||
def outFile = output.outputFile
|
||||
if (outFile != null && outFile.name.endsWith(".apk")) {
|
||||
def fileName = "${variant.productFlavors[0].name}" + "-${defaultConfig.versionName}-" + "${releaseTime()}" + ".apk"
|
||||
def fileName = "${defaultConfig.versionName}-" + "${releaseTime()}" + "-${variant.productFlavors[0].name}" +".apk"
|
||||
|
||||
outputFileName = fileName;
|
||||
}
|
||||
}
|
||||
|
||||
}*/
|
||||
}
|
||||
signingConfig signingConfigs.releaseConfig
|
||||
}
|
||||
}
|
||||
//渠道
|
||||
/*productFlavors {
|
||||
productFlavors {
|
||||
// googleplay {}
|
||||
A {
|
||||
applicationId "com.novelbook.android.a"
|
||||
qxs {
|
||||
applicationId "com.novelbook.android.qxs"
|
||||
versionName "version-a-1.0"
|
||||
buildConfigField "String", "MAIN_HOST", '"http://xiaoshuofenxiang.com/api/"'
|
||||
buildConfigField "String", "API_HOST", '"{\\"master\\":[\\"http:\\\\/\\\\/xiaoshuofenxiang.com\\"],\\"page\\":[\\"http:\\\\/\\\\/p.xiaoshuofenxiang.com\\"],\\"report\\":[\\"http:\\\\/\\\\/r.xiaoshuofenxiang.com\\"],\\"search\\":[\\"http:\\\\/\\\\/s.xiaoshuofenxiang.com\\"],\\"novel\\":[\\"http:\\\\/\\\\/n.xiaoshuofenxiang.com\\"],\\"novelsbydot\\":[\\"http:\\\\/\\\\/nbd.xiaoshuofenxiang.com\\"],\\"user\\":[\\"http:\\\\/\\\\/u.xiaoshuofenxiang.com\\"]}"'
|
||||
buildConfigField "String", "MAIN_HOST", '"http://chqxs.xiaoshuofenxiang.com/api/"'
|
||||
// buildConfigField "String", "API_HOST", '"{\\"master\\":[\\"http:\\\\/\\\\/qxs.xiaoshuofenxiang.com\\"],\\"page\\":[\\"http:\\\\/\\\\/p.xiaoshuofenxiang.com\\"],\\"report\\":[\\"http:\\\\/\\\\/r.xiaoshuofenxiang.com\\"],\\"search\\":[\\"http:\\\\/\\\\/s.xiaoshuofenxiang.com\\"],\\"novel\\":[\\"http:\\\\/\\\\/n.xiaoshuofenxiang.com\\"],\\"novelsbydot\\":[\\"http:\\\\/\\\\/nbd.xiaoshuofenxiang.com\\"],\\"user\\":[\\"http:\\\\/\\\\/u.xiaoshuofenxiang.com\\"]}"'
|
||||
buildConfigField "String", "API_HOST", '""'
|
||||
|
||||
}
|
||||
B {
|
||||
applicationId "com.novelbook.android.b"
|
||||
wzzw {
|
||||
applicationId "com.novelbook.android.wzzw"
|
||||
versionName "version-b-1.0"
|
||||
buildConfigField "String", "MAIN_HOST", '"http://xiaoshuofenxiang.com/api/"'
|
||||
buildConfigField "String", "API_HOST", '"{\\"master\\":[\\"http:\\\\/\\\\/xiaoshuofenxiang.com\\"],\\"page\\":[\\"http:\\\\/\\\\/p.xiaoshuofenxiang.com\\"],\\"report\\":[\\"http:\\\\/\\\\/r.xiaoshuofenxiang.com\\"],\\"search\\":[\\"http:\\\\/\\\\/s.xiaoshuofenxiang.com\\"],\\"novel\\":[\\"http:\\\\/\\\\/n.xiaoshuofenxiang.com\\"],\\"novelsbydot\\":[\\"http:\\\\/\\\\/nbd.xiaoshuofenxiang.com\\"],\\"user\\":[\\"http:\\\\/\\\\/u.xiaoshuofenxiang.com\\"]}"'
|
||||
|
||||
buildConfigField "String", "MAIN_HOST", '"http://chwzzw.xiaoshuofenxiang.com/api/"'
|
||||
// buildConfigField "String", "API_HOST", '"{\\"master\\":[\\"http:\\\\/\\\\/wzzw.xiaoshuofenxiang.com\\"],\\"page\\":[\\"http:\\\\/\\\\/p.xiaoshuofenxiang.com\\"],\\"report\\":[\\"http:\\\\/\\\\/r.xiaoshuofenxiang.com\\"],\\"search\\":[\\"http:\\\\/\\\\/s.xiaoshuofenxiang.com\\"],\\"novel\\":[\\"http:\\\\/\\\\/n.xiaoshuofenxiang.com\\"],\\"novelsbydot\\":[\\"http:\\\\/\\\\/nbd.xiaoshuofenxiang.com\\"],\\"user\\":[\\"http:\\\\/\\\\/u.xiaoshuofenxiang.com\\"]}"'
|
||||
buildConfigField "String", "API_HOST", '""'
|
||||
}
|
||||
C {
|
||||
applicationId "com.novelbook.android.c"
|
||||
bo {
|
||||
applicationId "com.novelbook.android.bo"
|
||||
versionName "version-c-1.0"
|
||||
buildConfigField "String", "MAIN_HOST", '"http://xiaoshuofenxiang.com/api/"'
|
||||
buildConfigField "String", "API_HOST", '"{\\"master\\":[\\"http:\\\\/\\\\/xiaoshuofenxiang.com\\"],\\"page\\":[\\"http:\\\\/\\\\/p.xiaoshuofenxiang.com\\"],\\"report\\":[\\"http:\\\\/\\\\/r.xiaoshuofenxiang.com\\"],\\"search\\":[\\"http:\\\\/\\\\/s.xiaoshuofenxiang.com\\"],\\"novel\\":[\\"http:\\\\/\\\\/n.xiaoshuofenxiang.com\\"],\\"novelsbydot\\":[\\"http:\\\\/\\\\/nbd.xiaoshuofenxiang.com\\"],\\"user\\":[\\"http:\\\\/\\\\/u.xiaoshuofenxiang.com\\"]}"'
|
||||
|
||||
buildConfigField "String", "MAIN_HOST", '"http://chbo.xiaoshuofenxiang.com/api/"'
|
||||
// buildConfigField "String", "API_HOST", '"{\\"master\\":[\\"http:\\\\/\\\\/bo.xiaoshuofenxiang.com\\"],\\"page\\":[\\"http:\\\\/\\\\/p.xiaoshuofenxiang.com\\"],\\"report\\":[\\"http:\\\\/\\\\/r.xiaoshuofenxiang.com\\"],\\"search\\":[\\"http:\\\\/\\\\/s.xiaoshuofenxiang.com\\"],\\"novel\\":[\\"http:\\\\/\\\\/n.xiaoshuofenxiang.com\\"],\\"novelsbydot\\":[\\"http:\\\\/\\\\/nbd.xiaoshuofenxiang.com\\"],\\"user\\":[\\"http:\\\\/\\\\/u.xiaoshuofenxiang.com\\"]}"'
|
||||
buildConfigField "String", "API_HOST", '""'
|
||||
}
|
||||
D {
|
||||
applicationId "com.novelbook.android.d"
|
||||
g {
|
||||
applicationId "com.novelbook.android.g"
|
||||
versionName "version-d-1.0"
|
||||
buildConfigField "String", "MAIN_HOST", '"http://xiaoshuofenxiang.com/api/"'
|
||||
buildConfigField "String", "API_HOST", '"{\\"master\\":[\\"http:\\\\/\\\\/xiaoshuofenxiang.com\\"],\\"page\\":[\\"http:\\\\/\\\\/p.xiaoshuofenxiang.com\\"],\\"report\\":[\\"http:\\\\/\\\\/r.xiaoshuofenxiang.com\\"],\\"search\\":[\\"http:\\\\/\\\\/s.xiaoshuofenxiang.com\\"],\\"novel\\":[\\"http:\\\\/\\\\/n.xiaoshuofenxiang.com\\"],\\"novelsbydot\\":[\\"http:\\\\/\\\\/nbd.xiaoshuofenxiang.com\\"],\\"user\\":[\\"http:\\\\/\\\\/u.xiaoshuofenxiang.com\\"]}"'
|
||||
|
||||
buildConfigField "String", "MAIN_HOST", '"http://chg.xiaoshuofenxiang.com/api/"'
|
||||
// buildConfigField "String", "API_HOST", '"{\\"master\\":[\\"http:\\\\/\\\\/xiaoshuofenxiang.com\\"],\\"page\\":[\\"http:\\\\/\\\\/p.xiaoshuofenxiang.com\\"],\\"report\\":[\\"http:\\\\/\\\\/r.xiaoshuofenxiang.com\\"],\\"search\\":[\\"http:\\\\/\\\\/s.xiaoshuofenxiang.com\\"],\\"novel\\":[\\"http:\\\\/\\\\/n.xiaoshuofenxiang.com\\"],\\"novelsbydot\\":[\\"http:\\\\/\\\\/nbd.xiaoshuofenxiang.com\\"],\\"user\\":[\\"http:\\\\/\\\\/u.xiaoshuofenxiang.com\\"]}"'
|
||||
buildConfigField "String", "API_HOST", '""'
|
||||
}
|
||||
//批量配置
|
||||
productFlavors.all { flavor ->
|
||||
flavor.manifestPlaceholders = [UMENG_CHANNEL_VALUE: name]
|
||||
}
|
||||
|
||||
}*/
|
||||
}
|
||||
android {
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
|
|
|
@ -16,31 +16,31 @@
|
|||
public *;
|
||||
}
|
||||
|
||||
#指定代码的压缩级别
|
||||
#ָ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ѹ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
-optimizationpasses 5
|
||||
|
||||
#包明不混合大小写
|
||||
#<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ϴ<EFBFBD>Сд
|
||||
-dontusemixedcaseclassnames
|
||||
|
||||
#不去忽略非公共的库类
|
||||
#<EFBFBD><EFBFBD>ȥ<EFBFBD><EFBFBD><EFBFBD>Էǹ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ŀ<EFBFBD><EFBFBD><EFBFBD>
|
||||
-dontskipnonpubliclibraryclasses
|
||||
|
||||
#优化 不优化输入的类文件
|
||||
#<EFBFBD>Ż<EFBFBD> <20><><EFBFBD>Ż<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ļ<EFBFBD>
|
||||
# -dontoptimize
|
||||
|
||||
#预校验
|
||||
#ԤУ<EFBFBD><EFBFBD>
|
||||
-dontpreverify
|
||||
|
||||
#混淆时是否记录日志
|
||||
#<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʱ<EFBFBD>Ƿ<EFBFBD><EFBFBD>¼<EFBFBD><EFBFBD>־
|
||||
-verbose
|
||||
|
||||
# 混淆时所采用的算法
|
||||
# <EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʱ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>õ<EFBFBD><EFBFBD>㷨
|
||||
-optimizations !code/simplification/arithmetic,!field/*,!class/merging/*
|
||||
|
||||
#保护注解
|
||||
#<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ע<EFBFBD><EFBFBD>
|
||||
-keepattributes *Annotation*
|
||||
|
||||
# 保持哪些类不被混淆
|
||||
# <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Щ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
-keep public class * extends android.app.Fragment
|
||||
-keep public class * extends android.app.Activity
|
||||
-keep public class * extends android.app.Application
|
||||
|
@ -50,25 +50,25 @@
|
|||
-keep public class * extends android.app.backup.BackupAgentHelper
|
||||
-keep public class * extends android.preference.Preference
|
||||
-keep public class com.android.vending.licensing.ILicensingService
|
||||
#如果有引用v4包可以添加下面这行
|
||||
#<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>v4<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
-keep public class * extends android.support.v4.app.Fragment
|
||||
|
||||
|
||||
#忽略警告
|
||||
#<EFBFBD><EFBFBD><EFBFBD>Ծ<EFBFBD><EFBFBD><EFBFBD>
|
||||
-ignorewarning
|
||||
|
||||
##记录生成的日志数据,gradle build时在本项目根目录输出##
|
||||
#apk 包内所有 class 的内部结构
|
||||
##<EFBFBD><EFBFBD>¼<EFBFBD><EFBFBD><EFBFBD>ɵ<EFBFBD><EFBFBD><EFBFBD>־<EFBFBD><EFBFBD><EFBFBD><EFBFBD>,gradle buildʱ<EFBFBD>ڱ<EFBFBD><EFBFBD><EFBFBD>Ŀ<EFBFBD><EFBFBD>Ŀ¼<EFBFBD><EFBFBD><EFBFBD>##
|
||||
#apk <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> class <20><><EFBFBD>ڲ<EFBFBD><EFBFBD>ṹ
|
||||
-dump proguard/class_files.txt
|
||||
#未混淆的类和成员
|
||||
#δ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ͳ<EFBFBD>Ա
|
||||
-printseeds proguard/seeds.txt
|
||||
#列出从 apk 中删除的代码
|
||||
#<EFBFBD>г<EFBFBD><EFBFBD><EFBFBD> apk <20><>ɾ<EFBFBD><EFBFBD><EFBFBD>Ĵ<EFBFBD><EFBFBD><EFBFBD>
|
||||
-printusage proguard/unused.txt
|
||||
#混淆前后的映射
|
||||
#<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ǰ<EFBFBD><EFBFBD><EFBFBD>ӳ<EFBFBD><EFBFBD>
|
||||
-printmapping proguard/mapping.txt
|
||||
########记录生成的日志数据,gradle build时 在本项目根目录输出-end######
|
||||
########<EFBFBD><EFBFBD>¼<EFBFBD><EFBFBD><EFBFBD>ɵ<EFBFBD><EFBFBD><EFBFBD>־<EFBFBD><EFBFBD><EFBFBD>ݣ<EFBFBD>gradle buildʱ <20>ڱ<EFBFBD><EFBFBD><EFBFBD>Ŀ<EFBFBD><EFBFBD>Ŀ¼<EFBFBD><EFBFBD><EFBFBD>-end######
|
||||
|
||||
#如果引用了v4或者v7包
|
||||
#<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>v4<EFBFBD><EFBFBD><EFBFBD><EFBFBD>v7<EFBFBD><EFBFBD>
|
||||
-dontwarn android.support.**
|
||||
-keep class com.google.** { *; }
|
||||
-keep class android.support.v4.**
|
||||
|
@ -76,21 +76,21 @@
|
|||
|
||||
-keep class android.support.v7.**
|
||||
-dontwarn android.support.v7.**
|
||||
####混淆保护自己项目的部分代码以及引用的第三方jar包library-end####
|
||||
####<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Լ<EFBFBD><EFBFBD><EFBFBD>Ŀ<EFBFBD>IJ<EFBFBD><EFBFBD>ִ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Լ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>õĵ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>jar<EFBFBD><EFBFBD>library-end####
|
||||
|
||||
|
||||
|
||||
#保持 native 方法不被混淆
|
||||
#<EFBFBD><EFBFBD><EFBFBD><EFBFBD> native <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
-keepclasseswithmembernames class * {
|
||||
native <methods>;
|
||||
}
|
||||
|
||||
#保持自定义控件类不被混淆
|
||||
#<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Զ<EFBFBD><EFBFBD><EFBFBD>ؼ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
-keepclasseswithmembers class * {
|
||||
public <init>(android.content.Context, android.util.AttributeSet);
|
||||
}
|
||||
|
||||
#保持自定义控件类不被混淆
|
||||
#<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Զ<EFBFBD><EFBFBD><EFBFBD>ؼ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
-keepclassmembers class * extends android.app.Activity {
|
||||
public void *(android.view.View);
|
||||
}
|
||||
|
@ -102,15 +102,15 @@
|
|||
public void set*(...);
|
||||
}
|
||||
|
||||
#保持 Parcelable 不被混淆
|
||||
#<EFBFBD><EFBFBD><EFBFBD><EFBFBD> Parcelable <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
-keep class * implements android.os.Parcelable {
|
||||
public static final android.os.Parcelable$Creator *;
|
||||
}
|
||||
|
||||
#保持 Serializable 不被混淆
|
||||
#<EFBFBD><EFBFBD><EFBFBD><EFBFBD> Serializable <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
-keepnames class * implements java.io.Serializable
|
||||
|
||||
#保持 Serializable 不被混淆并且enum 类也不被混淆
|
||||
#<EFBFBD><EFBFBD><EFBFBD><EFBFBD> Serializable <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>enum <20><>Ҳ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
-keepclassmembers class * implements java.io.Serializable {
|
||||
static final long serialVersionUID;
|
||||
private static final java.io.ObjectStreamField[] serialPersistentFields;
|
||||
|
@ -123,7 +123,7 @@
|
|||
java.lang.Object readResolve();
|
||||
}
|
||||
|
||||
#保持枚举 enum 类不被混淆
|
||||
#<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ö<EFBFBD><EFBFBD> enum <20><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
-keepclassmembers enum * {
|
||||
public static **[] values();
|
||||
public static ** valueOf(java.lang.String);
|
||||
|
@ -133,15 +133,15 @@
|
|||
public void *ButtonClicked(android.view.View);
|
||||
}
|
||||
|
||||
#不混淆资源类
|
||||
#<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Դ<EFBFBD><EFBFBD>
|
||||
-keepclassmembers class **.R$* {
|
||||
public static <fields>;
|
||||
}
|
||||
|
||||
#避免混淆泛型 如果混淆报错建议关掉
|
||||
#<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ص<EFBFBD>
|
||||
#-keepattributes Signature
|
||||
|
||||
#移除Log类打印各个等级日志的代码,打正式包的时候可以做为禁log使用,这里可以作为禁止log打印的功能使用,另外的一种实现方案是通过BuildConfig.DEBUG的变量来控制
|
||||
#<EFBFBD>Ƴ<EFBFBD>Log<EFBFBD><EFBFBD><EFBFBD>ӡ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ȼ<EFBFBD><EFBFBD><EFBFBD>־<EFBFBD>Ĵ<EFBFBD><EFBFBD>룬<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʽ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʱ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϊ<EFBFBD><EFBFBD>logʹ<EFBFBD>ã<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϊ<EFBFBD><EFBFBD>ֹlog<EFBFBD><EFBFBD>ӡ<EFBFBD>Ĺ<EFBFBD><EFBFBD><EFBFBD>ʹ<EFBFBD>ã<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>һ<EFBFBD><EFBFBD>ʵ<EFBFBD>ַ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ͨ<EFBFBD><EFBFBD>BuildConfig.DEBUG<EFBFBD>ı<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
#-assumenosideeffects class android.util.Log {
|
||||
# public static *** v(...);
|
||||
# public static *** i(...);
|
||||
|
@ -151,12 +151,12 @@
|
|||
#}
|
||||
|
||||
#############################################################################################
|
||||
######################## 以上通用 ##################################
|
||||
######################## <EFBFBD><EFBFBD><EFBFBD><EFBFBD>ͨ<EFBFBD><EFBFBD> ##################################
|
||||
#############################################################################################
|
||||
|
||||
####################### 常用第三方模块的混淆选项 ###################################
|
||||
####################### <EFBFBD><EFBFBD><EFBFBD>õ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ģ<EFBFBD><EFBFBD>Ļ<EFBFBD><EFBFBD><EFBFBD>ѡ<EFBFBD><EFBFBD> ###################################
|
||||
#gson
|
||||
#如果用用到Gson解析包的,直接添加下面这几行就能成功混淆,不然会报错。
|
||||
#<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>õ<EFBFBD>Gson<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ģ<EFBFBD>ֱ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⼸<EFBFBD>о<EFBFBD><EFBFBD>ܳɹ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ȼ<EFBFBD>ᱨ<EFBFBD><EFBFBD>
|
||||
-keepattributes Signature
|
||||
# Gson specific classes
|
||||
-keep class sun.misc.Unsafe { *; }
|
||||
|
@ -178,16 +178,16 @@
|
|||
@butterknife.* <methods>;
|
||||
}
|
||||
|
||||
######引用的其他Module可以直接在app的这个混淆文件里配置
|
||||
######<EFBFBD><EFBFBD><EFBFBD>õ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Module<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ֱ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>app<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ļ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
|
||||
# 如果使用了Gson之类的工具要使被它解析的JavaBean类即实体类不被混淆。
|
||||
# <EFBFBD><EFBFBD><EFBFBD>ʹ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Gson֮<EFBFBD><EFBFBD>Ĺ<EFBFBD><EFBFBD><EFBFBD>Ҫʹ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>JavaBean<EFBFBD>༴ʵ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
-keep class com.novelbook.android.bean.** { *; }
|
||||
-keep class com.novelbook.android.db.** { *; }
|
||||
#####混淆保护自己项目的部分代码以及引用的第三方jar包library#######
|
||||
#如果在当前的application module或者依赖的library module中使用了第三方的库,并不需要显式添加规则
|
||||
#####<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Լ<EFBFBD><EFBFBD><EFBFBD>Ŀ<EFBFBD>IJ<EFBFBD><EFBFBD>ִ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Լ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>õĵ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>jar<EFBFBD><EFBFBD>library#######
|
||||
#<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ڵ<EFBFBD>ǰ<EFBFBD><EFBFBD>application module<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>library module<EFBFBD><EFBFBD>ʹ<EFBFBD><EFBFBD><EFBFBD>˵<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ŀ⣬<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ҫ<EFBFBD><EFBFBD>ʽ<EFBFBD><EFBFBD>ӹ<EFBFBD><EFBFBD><EFBFBD>
|
||||
#-libraryjars xxx
|
||||
#添加了反而有可能在打包的时候遭遇同一个jar多次被指定的错误,一般只需要添加忽略警告和保持某些class不被混淆的声明。
|
||||
#以libaray的形式引用了开源项目,如果不想混淆 keep 掉,在引入的module的build.gradle中设置minifyEnabled=false
|
||||
#<EFBFBD><EFBFBD><EFBFBD><EFBFBD>˷<EFBFBD><EFBFBD><EFBFBD><EFBFBD>п<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ڴ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʱ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ͬһ<EFBFBD><EFBFBD>jar<EFBFBD><EFBFBD>α<EFBFBD>ָ<EFBFBD><EFBFBD><EFBFBD>Ĵ<EFBFBD><EFBFBD><EFBFBD>һ<EFBFBD><EFBFBD>ֻ<EFBFBD><EFBFBD>Ҫ<EFBFBD><EFBFBD>Ӻ<EFBFBD><EFBFBD>Ծ<EFBFBD><EFBFBD><EFBFBD>ͱ<EFBFBD><EFBFBD><EFBFBD>ijЩclass<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
#<EFBFBD><EFBFBD>libaray<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʽ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˿<EFBFBD>Դ<EFBFBD><EFBFBD>Ŀ,<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> keep <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>module<EFBFBD><EFBFBD>build.gradle<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>minifyEnabled=false
|
||||
|
||||
# banner
|
||||
-keep class com.youth.banner** { *; }
|
||||
|
@ -255,19 +255,19 @@
|
|||
public *;
|
||||
}
|
||||
|
||||
# 对于带有回调函数的onXXEvent、**On*Listener的,不能被混淆
|
||||
# <EFBFBD><EFBFBD><EFBFBD>ڴ<EFBFBD><EFBFBD>лص<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>onXXEvent<EFBFBD><EFBFBD>**On*Listener<EFBFBD>ģ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ܱ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
-keepclassmembers class * {
|
||||
void *(**On*Event);
|
||||
void *(**On*Listener);
|
||||
}
|
||||
|
||||
-assumenosideeffects class android.util.Log {
|
||||
public static boolean isLoggable(java.lang.String,int);
|
||||
public static int v(...);
|
||||
public static int i(...);
|
||||
public static int w(...);
|
||||
public static int d(...);
|
||||
public static int e(...);
|
||||
}
|
||||
# -assumenosideeffects class android.util.Log {
|
||||
# public static boolean isLoggable(java.lang.String,int);
|
||||
# public static int v(...);
|
||||
# public static int i(...);
|
||||
# public static int w(...);
|
||||
# public static int d(...);
|
||||
# public static int e(...);
|
||||
# }
|
||||
|
||||
|
||||
|
|
|
@ -99,8 +99,8 @@
|
|||
|
||||
<!-- UMENG -->
|
||||
<meta-data android:value="5cd6238a570df375c3000cc9" android:name="UMENG_APPKEY"/>
|
||||
<!--<meta-data android:name="UMENG_CHANNEL" android:value="${UMENG_CHANNEL_VALUE}"/>-->
|
||||
<meta-data android:value="debug" android:name="UMENG_CHANNEL"/>
|
||||
<meta-data android:name="UMENG_CHANNEL" android:value="${UMENG_CHANNEL_VALUE}"/>
|
||||
<!--<meta-data android:value="debug" android:name="UMENG_CHANNEL"/>-->
|
||||
<!-- <meta-data android:name="MAINHOST" android:value="${main_host}"/>
|
||||
<meta-data android:name="DEFAULTHOST" android:value="${default_host}"/>-->
|
||||
</application>
|
||||
|
|
|
@ -0,0 +1,164 @@
|
|||
package com.novelbook.android.AD;
|
||||
|
||||
import android.widget.FrameLayout;
|
||||
import android.content.Context;
|
||||
import android.graphics.Color;
|
||||
import android.os.CountDownTimer;
|
||||
import android.support.annotation.NonNull;
|
||||
import android.support.annotation.Nullable;
|
||||
import android.support.v7.widget.AppCompatImageView;
|
||||
import android.util.AttributeSet;
|
||||
import android.util.TypedValue;
|
||||
import android.view.Gravity;
|
||||
import android.view.View;
|
||||
import android.widget.FrameLayout;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.TextView;
|
||||
|
||||
public class AdvertisementView extends FrameLayout {
|
||||
|
||||
private final static String DEFAULT_COUNT_DOWN_FORMATTER_LABEL = "%1$ds\u2000跳过";
|
||||
/**
|
||||
* the code of clicking advertisement image
|
||||
*/
|
||||
public final static int ACTION_CODE_PREVIEW = 0x00;
|
||||
/**
|
||||
* the code of clicking jump_button
|
||||
*/
|
||||
public final static int ACTION_CODE_JUMP = 0x01;
|
||||
/**
|
||||
* the code of finishing count down timer
|
||||
*/
|
||||
public final static int ACTION_CODE_FINISH = 0x02;
|
||||
|
||||
private AppCompatImageView imageView;
|
||||
private TextView textView;
|
||||
private OnComponentActionListener onComponentActionListener;
|
||||
|
||||
private long millisInFuture;
|
||||
private long countDownInterval;
|
||||
private AdvertisementCountDownTimer advertisementCountDownTimer;
|
||||
private String countDownFormatterLabel = DEFAULT_COUNT_DOWN_FORMATTER_LABEL;
|
||||
|
||||
public AdvertisementView(@NonNull Context context) {
|
||||
this(context, null);
|
||||
}
|
||||
|
||||
public AdvertisementView(@NonNull Context context, @Nullable AttributeSet attrs) {
|
||||
this(context, attrs, 0);
|
||||
}
|
||||
|
||||
public AdvertisementView(@NonNull Context context, @Nullable AttributeSet attrs, int defStyleAttr) {
|
||||
super(context, attrs, defStyleAttr);
|
||||
init(context);
|
||||
}
|
||||
|
||||
private void init(Context context) {
|
||||
int dp8 = (int) TypedValue.applyDimension(TypedValue.COMPLEX_UNIT_DIP, 8, getResources().getDisplayMetrics());
|
||||
imageView = new AppCompatImageView(context);
|
||||
imageView.setScaleType(ImageView.ScaleType.CENTER_CROP);
|
||||
textView = new TextView(context);
|
||||
textView.setTextColor(Color.WHITE);
|
||||
textView.setGravity(Gravity.CENTER);
|
||||
textView.setPadding(dp8 * 2, 0, dp8 * 2, 0);
|
||||
textView.setTextSize(TypedValue.COMPLEX_UNIT_SP, 14f);
|
||||
// textView.setBackgroundResource(R.drawable.kit_jump_background_shape);
|
||||
addView(imageView, new LayoutParams(LayoutParams.MATCH_PARENT, LayoutParams.MATCH_PARENT));
|
||||
LayoutParams params = new LayoutParams(LayoutParams.WRAP_CONTENT, dp8 * 3);
|
||||
params.gravity = Gravity.END;
|
||||
params.rightMargin = dp8 * 2;
|
||||
params.topMargin = dp8 * 2;
|
||||
addView(textView, params);
|
||||
|
||||
|
||||
imageView.setOnClickListener(new OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
cancelCountDown();
|
||||
if (onComponentActionListener != null) {
|
||||
onComponentActionListener.onComponentAction(ACTION_CODE_PREVIEW, v);
|
||||
}
|
||||
}
|
||||
});
|
||||
textView.setOnClickListener(new OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
cancelCountDown();
|
||||
if (onComponentActionListener != null) {
|
||||
onComponentActionListener.onComponentAction(ACTION_CODE_JUMP, v);
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Because this is a formatter string, so it look like:"%1$d...".
|
||||
*
|
||||
* @param countDownFormatterLabel the formatter string
|
||||
* @see java.util.Formatter
|
||||
*/
|
||||
public void setCountDownFormatterLabel(String countDownFormatterLabel) {
|
||||
this.countDownFormatterLabel = countDownFormatterLabel;
|
||||
}
|
||||
|
||||
public String getCountDownFormatterLabel() {
|
||||
return countDownFormatterLabel;
|
||||
}
|
||||
|
||||
public AppCompatImageView getImageView() {
|
||||
return imageView;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param millisInFuture future time
|
||||
* @param countDownInterval interval count down step
|
||||
* @param onComponentActionListener action listener
|
||||
*/
|
||||
public void init(long millisInFuture, long countDownInterval, OnComponentActionListener onComponentActionListener) {
|
||||
this.millisInFuture = millisInFuture;
|
||||
this.countDownInterval = countDownInterval;
|
||||
this.onComponentActionListener = onComponentActionListener;
|
||||
textView.setText(String.format(countDownFormatterLabel, millisInFuture / 1000));
|
||||
}
|
||||
|
||||
public void startCountDown() {
|
||||
if (advertisementCountDownTimer == null) {
|
||||
advertisementCountDownTimer = new AdvertisementCountDownTimer(millisInFuture, countDownInterval);
|
||||
}
|
||||
advertisementCountDownTimer.start();
|
||||
}
|
||||
|
||||
public void cancelCountDown() {
|
||||
if (advertisementCountDownTimer != null) {
|
||||
advertisementCountDownTimer.cancel();
|
||||
advertisementCountDownTimer = null;
|
||||
}
|
||||
}
|
||||
|
||||
public interface OnComponentActionListener {
|
||||
void onComponentAction(int actionCode, View view);
|
||||
}
|
||||
|
||||
private class AdvertisementCountDownTimer extends CountDownTimer {
|
||||
|
||||
AdvertisementCountDownTimer(long millisInFuture, long countDownInterval) {
|
||||
super(millisInFuture, countDownInterval);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onTick(long millisUntilFinished) {
|
||||
long s = millisUntilFinished / 1000;
|
||||
textView.setText(String.format(countDownFormatterLabel, s));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onFinish() {
|
||||
textView.setText(String.format(countDownFormatterLabel, 0L));
|
||||
textView.setEnabled(false);
|
||||
cancelCountDown();
|
||||
if (onComponentActionListener != null) {
|
||||
onComponentActionListener.onComponentAction(ACTION_CODE_FINISH, textView);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,110 @@
|
|||
package com.novelbook.android.AD;
|
||||
import android.content.Intent;
|
||||
import android.content.res.AssetManager;
|
||||
import android.graphics.drawable.Drawable;
|
||||
import android.net.Uri;
|
||||
import android.os.Bundle;
|
||||
import android.support.annotation.Nullable;
|
||||
import android.support.v7.app.AppCompatActivity;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.view.WindowManager;
|
||||
import android.widget.TextView;
|
||||
|
||||
import com.novelbook.android.R;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.FileInputStream;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
|
||||
import butterknife.BindView;
|
||||
import butterknife.ButterKnife;
|
||||
|
||||
public class AdvertisementViewActivity extends AppCompatActivity {
|
||||
@BindView(R.id.adSplashView)
|
||||
AdvertisementView advertisementView;
|
||||
@BindView(R.id.textTile)
|
||||
TextView tvTitle;
|
||||
|
||||
@Override
|
||||
protected void onCreate(@Nullable Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
getWindow().addFlags(
|
||||
WindowManager.LayoutParams.FLAG_FULLSCREEN
|
||||
| WindowManager.LayoutParams.FLAG_KEEP_SCREEN_ON
|
||||
);
|
||||
// advertisementView = new AdvertisementView(this);
|
||||
// setContentView(advertisementView, new ViewGroup.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.MATCH_PARENT));
|
||||
setContentView(R.layout.activity_splash_ad);
|
||||
ButterKnife.bind(this);
|
||||
//获取ImageView, 设置显示图片
|
||||
//这样设计是为了方便调用者使用不同的图片加载框架。比如Picsso、Fresco、ImageLoader...
|
||||
// advertisementView.getImageView().setImageResource(R.drawable.header);
|
||||
/* String picPathName = "";
|
||||
if (new File(picPathName).exists()) {
|
||||
loadPicture(new File(picPathName));
|
||||
}
|
||||
else
|
||||
advertisementView.getImageView().setImageResource(R.drawable.header);*/
|
||||
loadPicture();
|
||||
advertisementView.init(5000, 1000, new AdvertisementView.OnComponentActionListener() {
|
||||
@Override
|
||||
public void onComponentAction(int actionCode, View view) {
|
||||
switch (actionCode) {//点击广告图片
|
||||
case AdvertisementView.ACTION_CODE_PREVIEW:
|
||||
String url = "http://www.baidu.com";
|
||||
startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse(url)));
|
||||
break;
|
||||
case AdvertisementView.ACTION_CODE_JUMP://点击跳过
|
||||
break;
|
||||
case AdvertisementView.ACTION_CODE_FINISH://倒计时结束
|
||||
break;
|
||||
}
|
||||
//因为广告图片可能比较大,所以我们主动移除所有子view,加快GC回收
|
||||
advertisementView.removeAllViews();
|
||||
System.gc();
|
||||
finish();
|
||||
}
|
||||
});
|
||||
|
||||
tvTitle.setText(R.string.app_name);
|
||||
}
|
||||
|
||||
private void loadPicture(/*File file*/) {
|
||||
InputStream is = null;
|
||||
try {
|
||||
// is = new FileInputStream(file);
|
||||
is =getAssets().open("ad.jpg");
|
||||
|
||||
Drawable drawable = Drawable.createFromStream(is, null);
|
||||
advertisementView.getImageView().setImageDrawable(drawable);
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
} finally {
|
||||
try {
|
||||
if (is != null)
|
||||
is.close();
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onResume() {
|
||||
super.onResume();
|
||||
advertisementView.startCountDown();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onBackPressed() {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onPause() {
|
||||
advertisementView.cancelCountDown();
|
||||
super.onPause();
|
||||
}
|
||||
}
|
|
@ -0,0 +1,116 @@
|
|||
package com.novelbook.android.AD;
|
||||
|
||||
import android.app.Activity;
|
||||
import android.app.Application;
|
||||
import android.content.ComponentCallbacks2;
|
||||
import android.content.Intent;
|
||||
import android.content.res.Configuration;
|
||||
import android.os.Build;
|
||||
import android.os.Bundle;
|
||||
import android.util.Log;
|
||||
|
||||
import com.novelbook.android.Main2Activity;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
public class SplashAdManager implements Application.ActivityLifecycleCallbacks, ComponentCallbacks2 {
|
||||
private boolean mIsBackground;
|
||||
private static long lastAd =0;
|
||||
private static long interVal = 5*60*1000; //间隔5分钟
|
||||
/******
|
||||
* 使用方式:在Application中直接构造即可
|
||||
* @param application
|
||||
*/
|
||||
public SplashAdManager(Application application) {
|
||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.ICE_CREAM_SANDWICH) {
|
||||
application.registerActivityLifecycleCallbacks(this);
|
||||
application.registerComponentCallbacks(this);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/*****
|
||||
* 解除绑定
|
||||
*/
|
||||
public void release(Application application) {
|
||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.ICE_CREAM_SANDWICH) {
|
||||
application.unregisterActivityLifecycleCallbacks(this);
|
||||
application.unregisterComponentCallbacks(this);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onActivityCreated(Activity activity, Bundle savedInstanceState) {
|
||||
if(activity instanceof Main2Activity){
|
||||
|
||||
showAd(activity);
|
||||
Log.d("zzr", " 启动应用");
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onActivityStarted(Activity activity) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onActivityResumed(Activity activity) {
|
||||
if (mIsBackground) {
|
||||
mIsBackground = false;
|
||||
|
||||
showAd(activity);
|
||||
|
||||
Log.d("zzr", "从广告页回到前台");
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onActivityPaused(Activity activity) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onActivityStopped(Activity activity) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onActivitySaveInstanceState(Activity activity, Bundle outState) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onActivityDestroyed(Activity activity) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onTrimMemory(int level) {
|
||||
//监听应用是否退到后台
|
||||
if (level == TRIM_MEMORY_UI_HIDDEN) {
|
||||
mIsBackground = true;
|
||||
Log.i("zzr", "应用退出到后台");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public void onConfigurationChanged(Configuration newConfig) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onLowMemory() {
|
||||
|
||||
}
|
||||
|
||||
void showAd(Activity activity){
|
||||
if(canShowAd()) {
|
||||
lastAd = new Date().getTime();
|
||||
activity.startActivity(new Intent(activity, AdvertisementViewActivity.class));
|
||||
}
|
||||
}
|
||||
boolean canShowAd(){
|
||||
return new Date().getTime() -lastAd >interVal;
|
||||
}
|
||||
}
|
|
@ -216,7 +216,7 @@ public abstract class Activity_base extends AppCompatActivity {
|
|||
if (mProgressDialog == null) {
|
||||
mProgressDialog = new ProgressDialog(this);
|
||||
mProgressDialog.setProgressStyle(ProgressDialog.STYLE_SPINNER);
|
||||
mProgressDialog.setCancelable(flag);
|
||||
mProgressDialog.setCancelable(true);
|
||||
mProgressDialog.setCanceledOnTouchOutside(false);
|
||||
mProgressDialog.setMessage(message);
|
||||
}
|
||||
|
|
|
@ -90,7 +90,7 @@ public class BookMarkFragment extends BasicFragment implements MarkActivity.Sor
|
|||
@Override
|
||||
public void onItemClick(AdapterView<?> parent, View view, int position, long id) {
|
||||
|
||||
if( pageFactory.getmAd()==null){
|
||||
// if( pageFactory.getmAd()==null){
|
||||
showProgressDialog(true,"正在加载");
|
||||
Novel nv = LitePal.find(Novel.class,novelId);
|
||||
nv.setLastReadChapt(bookMarksList.get(position).getChapt());
|
||||
|
@ -101,9 +101,9 @@ public class BookMarkFragment extends BasicFragment implements MarkActivity.Sor
|
|||
// Log.d(TAG, String.format("prepare book %s 开始open book.",nv.getName()) );
|
||||
ReadActivity.openBook(nv ,activity);
|
||||
handler.sendEmptyMessage(99);
|
||||
}else{
|
||||
/* }else{
|
||||
pageFactory.openBookmark(bookMarksList.get(position).getChapt(),bookMarksList.get(position).getBegin());
|
||||
}
|
||||
}*/
|
||||
|
||||
getActivity().finish();
|
||||
}
|
||||
|
|
|
@ -29,7 +29,7 @@ public class MyApp extends Application {
|
|||
LogcatHelper.getInstance(this).start();
|
||||
// BlurKit.init(this);
|
||||
LitePal.initialize(this);
|
||||
splashAdManager = new SplashAdManager(this);
|
||||
// splashAdManager = new SplashAdManager(this);
|
||||
initApi();
|
||||
}
|
||||
|
||||
|
|
|
@ -12,6 +12,7 @@ import com.novelbook.android.utils.CommonUtil;
|
|||
import com.novelbook.android.utils.Config;
|
||||
import com.novelbook.android.utils.Constants;
|
||||
|
||||
import org.json.JSONException;
|
||||
import org.json.JSONObject;
|
||||
|
||||
import java.util.Date;
|
||||
|
@ -63,25 +64,35 @@ public class NetUtil {
|
|||
}
|
||||
|
||||
public static JSONObject getHost(boolean isMainApi) {
|
||||
JSONObject jsonObject=null;
|
||||
if(!isMainApi && isHostExpires()){
|
||||
Log.d(TAG, String.format("isHostExpires prepare book: main API maxAge %s, is expired, loading main API again ",CommonUtil.getTimeCnt4Read(Constants.MAXAGE_G*1000,true)));
|
||||
getHostPolicy();
|
||||
}
|
||||
if (TextUtils.isEmpty(hosts)){
|
||||
if (TextUtils.isEmpty(hosts)) {
|
||||
Config config = Config.getInstance();
|
||||
hosts = config.getBaseUrl();
|
||||
if(TextUtils.isEmpty(hosts)){
|
||||
return null;
|
||||
}
|
||||
}
|
||||
try {
|
||||
jsonObject = new JSONObject(hosts);
|
||||
|
||||
if (jsonObject != null && TextUtils.isEmpty(Constants.announcement)) {
|
||||
|
||||
initHostConstants(jsonObject);
|
||||
}
|
||||
} catch (JSONException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
Log.d(TAG, "getUrl: host is " + hosts);
|
||||
if (TextUtils.isEmpty(hosts)) {
|
||||
Log.e(TAG, "getHosts: error on get hosts");
|
||||
}
|
||||
|
||||
try {
|
||||
return new JSONObject(hosts);
|
||||
} catch (Exception er) {
|
||||
|
||||
}
|
||||
return null;
|
||||
return jsonObject;
|
||||
}
|
||||
/**
|
||||
* 判断是否有网络连接
|
||||
|
@ -315,9 +326,8 @@ public class NetUtil {
|
|||
//config.setBaseUrl(resultstr);
|
||||
hosts="";
|
||||
Constants.LAST_G = new Date().getTime();
|
||||
|
||||
Constants.announcement =jsonObject.getString("declare");
|
||||
Constants.email =jsonObject.getString("email");
|
||||
initHostConstants(jsonObject);
|
||||
// Constants.minVersion =
|
||||
// config.setRootUrl( jsonObject.getString("masterDomains"));
|
||||
isRequestHosts =false;
|
||||
} catch (Exception e) {
|
||||
|
@ -336,5 +346,13 @@ public class NetUtil {
|
|||
}, MyApp.applicationContext));
|
||||
}
|
||||
|
||||
static void initHostConstants( JSONObject jsonObject ) throws JSONException {
|
||||
Constants.announcement =jsonObject.getString("declare");
|
||||
Constants.email =jsonObject.getString("email");
|
||||
String tmp =jsonObject.getString("upgradeUrl");
|
||||
Constants.updateUrl =TextUtils.isEmpty(tmp)?Constants.updateUrl:tmp;
|
||||
// Constants.minVersion = jsonObject.getString("minVersion"); //TODO minVersion to be int type
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -26,6 +26,7 @@ import android.os.Environment;
|
|||
import android.os.Handler;
|
||||
import android.os.Message;
|
||||
import android.support.v4.content.FileProvider;
|
||||
import android.text.TextUtils;
|
||||
import android.util.Log;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
|
@ -52,6 +53,7 @@ import okhttp3.Response;
|
|||
import okhttp3.ResponseBody;
|
||||
|
||||
import static com.novelbook.android.netapi.URLConstant.getRootUrl;
|
||||
import static java.lang.System.exit;
|
||||
|
||||
|
||||
public class UpdateManager {
|
||||
|
@ -69,6 +71,7 @@ public class UpdateManager {
|
|||
private Context mContext;
|
||||
private ProgressBar mProgress;
|
||||
private Dialog mDownloadDialog;
|
||||
private boolean isForceRefresh;
|
||||
private Handler mHandler = new Handler()
|
||||
{
|
||||
@Override
|
||||
|
@ -103,7 +106,8 @@ public class UpdateManager {
|
|||
public void checkUpdate()
|
||||
{
|
||||
String urlStr = getRootUrl()+ Constants.VERSION_ADDRESS;
|
||||
urlStr ="http://xiaoshuofenxiang.com/version.xml";
|
||||
urlStr = Constants.updateUrl;//"http://xiaoshuofenxiang.com/version.xml";
|
||||
if(!TextUtils.isEmpty(urlStr))
|
||||
checkUpdate(urlStr);
|
||||
/*if (isUpdate())
|
||||
{
|
||||
|
@ -192,8 +196,11 @@ public class UpdateManager {
|
|||
mHashMap = multiHashMap.get(packgename);
|
||||
if (mHashMap != null) {
|
||||
int serviceCode = Integer.valueOf(mHashMap.get("version"));
|
||||
if(mHashMap.containsKey("miniVersion"))
|
||||
Constants.minVersion = Integer.valueOf(mHashMap.get("miniVersion"));
|
||||
// need update or not
|
||||
isUpdate = serviceCode > versionCode;
|
||||
isForceRefresh = serviceCode <Constants.minVersion;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -299,12 +306,18 @@ public class UpdateManager {
|
|||
*/
|
||||
private void showNoticeDialog()
|
||||
{
|
||||
|
||||
// 閺嬪嫰锟界<EFBFBD>纭呯樈濡楋拷
|
||||
Builder builder = new Builder(mContext);
|
||||
builder.setTitle(R.string.soft_update_title);
|
||||
String upgradeDetails=mHashMap.get("details");
|
||||
|
||||
builder.setMessage( mContext.getPackageName() + " "+getVersionCode(mContext) +" " +mContext.getString(R.string.soft_update_info) +upgradeDetails );
|
||||
if(isForceRefresh) {
|
||||
builder.setTitle(R.string.soft_force_update_title);
|
||||
}else {
|
||||
builder.setTitle(R.string.soft_update_title);
|
||||
}
|
||||
String upgradeDetails=mHashMap.get("details");
|
||||
String forceRefresh =isForceRefresh? "本地版本过低,请升级新版本\n":"";
|
||||
builder.setMessage( forceRefresh + mContext.getPackageName() + " "+getVersionCode(mContext) +" " +mContext.getString(R.string.soft_update_info) + upgradeDetails );
|
||||
builder.setPositiveButton(R.string.soft_update_updatebtn, new OnClickListener()
|
||||
{
|
||||
@Override
|
||||
|
@ -321,6 +334,9 @@ public class UpdateManager {
|
|||
public void onClick(DialogInterface dialog, int which)
|
||||
{
|
||||
dialog.dismiss();
|
||||
if(isForceRefresh){
|
||||
exit(-1);
|
||||
}
|
||||
}
|
||||
});
|
||||
Dialog noticeDialog = builder.create();
|
||||
|
@ -351,6 +367,9 @@ public class UpdateManager {
|
|||
dialog.dismiss();
|
||||
// 鐠佸墽鐤嗛崣鏍ㄧХ閻樿埖锟<EFBFBD>
|
||||
cancelUpdate = true;
|
||||
if(isForceRefresh){
|
||||
exit(-1);
|
||||
}
|
||||
}
|
||||
});
|
||||
mDownloadDialog = builder.create();
|
||||
|
|
|
@ -1302,7 +1302,7 @@ int muluRetryCount =0;
|
|||
return cachedPath + mNovel.getName() + index ;
|
||||
}
|
||||
public String fileChapterName(int chaptId ) {
|
||||
if(!TextUtils.isEmpty(mNovel.getDomain())){
|
||||
if(mNovel!=null && !TextUtils.isEmpty(mNovel.getDomain())){
|
||||
|
||||
return getChapterPath() +mNovel.getDomain()+"/"+ chaptId ;
|
||||
}
|
||||
|
|
|
@ -31,5 +31,6 @@ public class Constants {
|
|||
public static boolean showDialogOnUiPage =false;
|
||||
public static String announcement ="免责声明:阅读内容均来自互联网,本软件仅提供转码服务";
|
||||
public static String email ="";
|
||||
|
||||
public static int minVersion =0;
|
||||
public static String updateUrl="http://xiaoshuofenxiang.com/version.xml";;
|
||||
}
|
||||
|
|
|
@ -0,0 +1,23 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
android:layout_gravity="center">
|
||||
<com.novelbook.android.AD.AdvertisementView
|
||||
android:id="@+id/adSplashView"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_weight="1"
|
||||
/>
|
||||
|
||||
<TextView android:id="@+id/textTile"
|
||||
android:layout_gravity="center"
|
||||
android:gravity="center"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="50dp"
|
||||
android:textSize="20sp"
|
||||
android:textStyle="bold"
|
||||
android:text="" />
|
||||
|
||||
</LinearLayout>
|
|
@ -1,5 +1,5 @@
|
|||
<resources>
|
||||
<string name="app_name">未知</string>
|
||||
<string name="app_name">味知阅读</string>
|
||||
<string name="title_home">书架</string>
|
||||
<string name="title_dashboard">书城</string>
|
||||
<string name="title_notifications">排行榜</string>
|
||||
|
@ -193,6 +193,7 @@
|
|||
<string name="refresh">重试</string>
|
||||
<string name="soft_update_no">已是最新版本</string>
|
||||
<string name="soft_update_title">有新版本了</string>
|
||||
<string name="soft_force_update_title">强制更新</string>
|
||||
<string name="soft_update_info">更新日志</string>
|
||||
<string name="soft_update_updatebtn">更新</string>
|
||||
<string name="soft_update_later">以后再说</string>
|
||||
|
|
|
@ -8,38 +8,80 @@
|
|||
</facet>
|
||||
<facet type="android" name="Android">
|
||||
<configuration>
|
||||
<option name="SELECTED_BUILD_VARIANT" value="debug" />
|
||||
<option name="ASSEMBLE_TASK_NAME" value="assembleDebug" />
|
||||
<option name="COMPILE_JAVA_TASK_NAME" value="compileDebugSources" />
|
||||
<option name="SELECTED_BUILD_VARIANT" value="boDebug" />
|
||||
<option name="ASSEMBLE_TASK_NAME" value="assembleBoDebug" />
|
||||
<option name="COMPILE_JAVA_TASK_NAME" value="compileBoDebugSources" />
|
||||
<afterSyncTasks>
|
||||
<task>generateDebugSources</task>
|
||||
<task>generateBoDebugSources</task>
|
||||
</afterSyncTasks>
|
||||
<option name="ALLOW_USER_CONFIGURATION" value="false" />
|
||||
<option name="MANIFEST_FILE_RELATIVE_PATH" value="/src/main/AndroidManifest.xml" />
|
||||
<option name="RES_FOLDER_RELATIVE_PATH" value="/src/main/res" />
|
||||
<option name="RES_FOLDERS_RELATIVE_PATH" value="file://$MODULE_DIR$/src/main/res" />
|
||||
<option name="RES_FOLDERS_RELATIVE_PATH" value="file://$MODULE_DIR$/src/main/res;file://$MODULE_DIR$/src/bo/res" />
|
||||
<option name="ASSETS_FOLDER_RELATIVE_PATH" value="/src/main/assets" />
|
||||
</configuration>
|
||||
</facet>
|
||||
</component>
|
||||
<component name="NewModuleRootManager" LANGUAGE_LEVEL="JDK_1_8">
|
||||
<output url="file://$MODULE_DIR$/build/intermediates/javac/debug/compileDebugJavaWithJavac/classes" />
|
||||
<output-test url="file://$MODULE_DIR$/build/intermediates/javac/debugUnitTest/compileDebugUnitTestJavaWithJavac/classes" />
|
||||
<output url="file://$MODULE_DIR$/build/intermediates/javac/boDebug/compileBoDebugJavaWithJavac/classes" />
|
||||
<output-test url="file://$MODULE_DIR$/build/intermediates/javac/boDebugUnitTest/compileBoDebugUnitTestJavaWithJavac/classes" />
|
||||
<exclude-output />
|
||||
<content url="file://$MODULE_DIR$">
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/apt/debug" isTestSource="false" generated="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/aidl_source_output_dir/debug/compileDebugAidl/out" isTestSource="false" generated="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/buildConfig/debug" isTestSource="false" generated="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/renderscript_source_output_dir/debug/compileDebugRenderscript/out" isTestSource="false" generated="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/rs/debug" type="java-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/resValues/debug" type="java-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/apt/androidTest/debug" isTestSource="true" generated="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/aidl_source_output_dir/debugAndroidTest/compileDebugAndroidTestAidl/out" isTestSource="true" generated="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/buildConfig/androidTest/debug" isTestSource="true" generated="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/renderscript_source_output_dir/debugAndroidTest/compileDebugAndroidTestRenderscript/out" isTestSource="true" generated="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/rs/androidTest/debug" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/resValues/androidTest/debug" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/apt/test/debug" isTestSource="true" generated="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/apt/bo/debug" isTestSource="false" generated="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/aidl_source_output_dir/boDebug/compileBoDebugAidl/out" isTestSource="false" generated="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/buildConfig/bo/debug" isTestSource="false" generated="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/renderscript_source_output_dir/boDebug/compileBoDebugRenderscript/out" isTestSource="false" generated="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/rs/bo/debug" type="java-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/resValues/bo/debug" type="java-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/boDebug/res" type="java-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/boDebug/resources" type="java-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/boDebug/assets" type="java-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/boDebug/aidl" isTestSource="false" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/boDebug/java" isTestSource="false" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/boDebug/rs" isTestSource="false" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/boDebug/shaders" isTestSource="false" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/apt/androidTest/bo/debug" isTestSource="true" generated="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/aidl_source_output_dir/boDebugAndroidTest/compileBoDebugAndroidTestAidl/out" isTestSource="true" generated="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/buildConfig/androidTest/bo/debug" isTestSource="true" generated="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/renderscript_source_output_dir/boDebugAndroidTest/compileBoDebugAndroidTestRenderscript/out" isTestSource="true" generated="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/rs/androidTest/bo/debug" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/resValues/androidTest/bo/debug" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTestBoDebug/res" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTestBoDebug/resources" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTestBoDebug/assets" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTestBoDebug/aidl" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTestBoDebug/java" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTestBoDebug/rs" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTestBoDebug/shaders" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/apt/test/bo/debug" isTestSource="true" generated="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testBoDebug/res" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testBoDebug/resources" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testBoDebug/assets" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testBoDebug/aidl" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testBoDebug/java" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testBoDebug/rs" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testBoDebug/shaders" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/bo/res" type="java-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/bo/resources" type="java-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/bo/assets" type="java-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/bo/aidl" isTestSource="false" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/bo/java" isTestSource="false" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/bo/rs" isTestSource="false" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/bo/shaders" isTestSource="false" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTestBo/res" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTestBo/resources" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTestBo/assets" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTestBo/aidl" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTestBo/java" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTestBo/rs" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTestBo/shaders" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testBo/res" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testBo/resources" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testBo/assets" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testBo/aidl" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testBo/java" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testBo/rs" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testBo/shaders" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/debug/res" type="java-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/debug/resources" type="java-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/debug/assets" type="java-resource" />
|
||||
|
@ -87,25 +129,16 @@
|
|||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/annotation_processor_list" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/apk_list" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/blame" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/build-info" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/builds" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/bundle_manifest" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/check_manifest_result" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/compatible_screen_manifest" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/incremental" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/incremental-runtime-classes" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/incremental-verifier" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/instant-run-apk" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/instant_app_manifest" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/instant_run_app_info_output_file" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/instant_run_main_apk_resources" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/instant_run_merged_manifests" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/instant_run_split_apk_resources" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/javac" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/jniLibs" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/legacy_multidex_aapt_derived_proguard_rules" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/legacy_multidex_main_dex_list" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/manifest-checker" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/merged-not-compiled-resources" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/merged_assets" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/merged_manifests" />
|
||||
|
@ -114,15 +147,12 @@
|
|||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/processed_res" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/proguard-files" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/proguard-rules" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/reload-dex" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/res" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/res_stripped" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/resources" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/rs" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/shader_assets" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/shaders" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/signing_config" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/split-apk" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/symbols" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/transforms" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/outputs" />
|
||||
|
|
Loading…
Reference in New Issue