Skip to content

Commit 8a64952

Browse files
committed
升级gradle 6.1修复 一些bug
1 parent 37e0cd7 commit 8a64952

File tree

13 files changed

+45
-34
lines changed

13 files changed

+45
-34
lines changed

app/build.gradle

+21-7
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
apply plugin: 'com.android.application'
2+
apply plugin: 'com.jakewharton.butterknife'
23
apply plugin: 'kotlin-android'
34
apply plugin: 'kotlin-android-extensions'
4-
apply plugin: 'com.jakewharton.butterknife'
5+
apply plugin: 'kotlin-kapt'
56

67
def AAVersion = '4.5.2'
78
def SupportLibVersion = '28.0.0'
@@ -24,6 +25,16 @@ android {
2425
versionName versions.appVersionName
2526
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
2627
multiDexEnabled true
28+
javaCompileOptions {
29+
annotationProcessorOptions {
30+
arguments = [
31+
'resourcePackageName': applicationId,
32+
"androidManifestFile": "$projectDir/src/main/AndroidManifest.xml".toString()
33+
]
34+
}
35+
}
36+
37+
2738
}
2839
buildTypes {
2940
debug {
@@ -104,17 +115,19 @@ dependencies {
104115
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-android:1.0.1"
105116
// Android Annotations
106117
annotationProcessor "org.androidannotations:androidannotations:$AAVersion"
118+
kapt "org.androidannotations:androidannotations:$AAVersion"
107119
implementation "org.androidannotations:androidannotations-api:$AAVersion"
108120
// ButterKnife
109-
implementation('com.jakewharton:butterknife:9.0.0-rc2', {
121+
implementation('com.jakewharton:butterknife:10.2.1', {
110122
exclude group: 'com.android.support'
111123
})
112-
annotationProcessor 'com.jakewharton:butterknife-compiler:9.0.0-rc2'
124+
annotationProcessor 'com.jakewharton:butterknife-compiler:10.2.1'
125+
kapt 'com.jakewharton:butterknife-compiler:10.2.1'
113126
// Android supports
114-
implementation 'androidx.appcompat:appcompat:1.0.2'
127+
implementation 'androidx.appcompat:appcompat:1.2.0'
115128
implementation 'androidx.cardview:cardview:1.0.0'
116-
implementation 'com.google.android.material:material:1.1.0-alpha01'
117-
implementation 'androidx.multidex:multidex:2.0.0'
129+
implementation 'com.google.android.material:material:1.3.0-alpha02'
130+
implementation 'androidx.multidex:multidex:2.0.1'
118131
// Personal libraries
119132
implementation 'com.github.hyb1996:MutableTheme:1.0.0'
120133
// Material Dialogs
@@ -147,7 +160,7 @@ dependencies {
147160
implementation "io.reactivex.rxjava2:rxjava:2.1.2"
148161
implementation 'io.reactivex.rxjava2:rxandroid:2.0.1'
149162
// Retrofit
150-
implementation 'com.squareup.retrofit2:retrofit:2.3.0'
163+
implementation 'com.squareup.retrofit2:retrofit:2.4.0'
151164
implementation 'com.squareup.retrofit2:converter-gson:2.3.0'
152165
implementation 'com.squareup.retrofit2:converter-gson:2.3.0'
153166
implementation 'com.jakewharton.retrofit:retrofit2-rxjava2-adapter:1.0.0'
@@ -157,6 +170,7 @@ dependencies {
157170
exclude group: 'com.android.support'
158171
})
159172
kapt 'com.github.bumptech.glide:compiler:4.8.0'
173+
annotationProcessor 'com.github.bumptech.glide:compiler:4.8.0'
160174
//joda time
161175
implementation 'joda-time:joda-time:2.9.9'
162176
// Tasker Plugin

app/src/main/java/org/autojs/autojs/ui/floating/layoutinspector/NodeInfoView.kt

+1-3
Original file line numberDiff line numberDiff line change
@@ -96,9 +96,7 @@ class NodeInfoView : RecyclerView {
9696

9797
internal inner class ViewHolder(itemView: View) : RecyclerView.ViewHolder(itemView) {
9898

99-
@BindView(R.id.name)
100-
val attrName: TextView = itemView.findViewById(R.id.name)
101-
99+
val attrName: TextView = itemView.findViewById(R.id.name);
102100
val attrValue: TextView = itemView.findViewById(R.id.value)
103101

104102
init {

app/src/main/java/org/autojs/autojs/ui/main/market/ImageText.kt

+1-1
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ class ImageText : LinearLayout {
3939
a.getString(R.styleable.ImageText_text)?.let {
4040
textView.text = it
4141
}
42-
val iconResId = a.getResourceId(R.styleable.ImageText_src, 0)
42+
val iconResId = a.getResourceId(R.styleable.ImageText_altSrc, 0)
4343
if (iconResId != 0) {
4444
imageView.setImageResource(iconResId)
4545
}

app/src/main/res/layout/item_topic.xml

+4-4
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@
101101
android:background="?selectableItemBackgroundBorderless"
102102
android:tint="#939393"
103103
app:image_width="30dp"
104-
app:src="@drawable/download"
104+
app:altSrc="@drawable/download"
105105
app:text="@string/text_download"/>
106106

107107
<org.autojs.autojs.ui.main.market.ImageText
@@ -111,7 +111,7 @@
111111
android:layout_weight="1"
112112
android:background="?selectableItemBackgroundBorderless"
113113
app:image_width="30dp"
114-
app:src="@drawable/upvote"/>
114+
app:altSrc="@drawable/upvote"/>
115115

116116
<org.autojs.autojs.ui.main.market.ImageText
117117
android:id="@+id/downvote"
@@ -120,7 +120,7 @@
120120
android:layout_weight="1"
121121
android:background="?selectableItemBackgroundBorderless"
122122
app:image_width="30dp"
123-
app:src="@drawable/downvote"/>
123+
app:altSrc="@drawable/downvote"/>
124124

125125
<org.autojs.autojs.ui.main.market.ImageText
126126
android:id="@+id/star"
@@ -129,7 +129,7 @@
129129
android:layout_weight="1"
130130
android:background="?selectableItemBackgroundBorderless"
131131
app:image_width="30dp"
132-
app:src="@drawable/star"
132+
app:altSrc="@drawable/star"
133133
app:text="@string/text_star"/>
134134

135135
</LinearLayout>

app/src/main/res/layout/preference_category_custom.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
android:orientation="vertical">
77

88
<TextView
9-
android:id="@+android:id/title"
9+
android:id="@android:id/title"
1010
android:layout_width="match_parent"
1111
android:layout_height="wrap_content"
1212
android:gravity="center_vertical"

app/src/main/res/values/attrs.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737

3838
<declare-styleable name="ImageText">
3939
<attr name="text"/>
40-
<attr name="src"/>
40+
<attr name="altSrc"/>
4141
<attr name="image_width" format="dimension|reference"/>
4242
</declare-styleable>
4343

app/src/main/res/values/strings.xml

+7-7
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<string name="text_please_input_name">请输入名称</string>
66
<string name="text_name">名称</string>
77
<string name="text_go_to_setting">去设置</string>
8-
<string name="explain_accessibility_permission">软件需要打开\"无障碍服务\"才能运行,请在随后的设置中选择\"Auto.js\"并开启服务。\n您也可以稍后在侧拉菜单中设置。</string>
8+
<string name="explain_accessibility_permission">软件需要打开\"无障碍服务\"才能运行,请在随后的设置中选择\"Autox.js\"并开启服务。\n您也可以稍后在侧拉菜单中设置。</string>
99
<string name="text_cancel">取消</string>
1010
<string name="text_path_is_empty">路径为空</string>
1111
<string name="text_file_not_exists">文件不存在</string>
@@ -27,14 +27,14 @@
2727
<string name="text_about">关于</string>
2828
<string name="text_licenses">开放源代码许可</string>
2929
<string name="text_do_not_remind_again">不再提示</string>
30-
<string name="copyright">Copyright©2018-2019 All right reserves.</string>
31-
<string name="developer">星尘幻影</string>
32-
<string name="qq" translatable="false">2732014414</string>
33-
<string name="email" translatable="false">hybbbb1996@gmail.com</string>
30+
<string name="copyright">Copyright©2020-2025 All right reserves.</string>
31+
<string name="developer">aaron</string>
32+
<string name="qq" translatable="false">470722660</string>
33+
<string name="email" translatable="false">kkevsekk@163.com</string>
3434
<string name="github">软件源代码</string>
3535
<string name="text_already_copy_to_clip">已复制到剪贴板</string>
36-
<string name="my_github">https://github.com/hyb1996/NoRootScriptDroid</string>
37-
<string name="share_app">[Auto.js]下载地址:http://www.coolapk.com/apk/org.autojs.autojs </string>
36+
<string name="my_github">https://github.com/kkevsekk1/autox</string>
37+
<string name="share_app">[Autox.js]下载地址:https://github.com/kkevsekk1/AutoX/releases </string>
3838
<string name="text_floating_window">悬浮窗</string>
3939
<string name="text_error_report">错误报告</string>
4040
<string name="text_press_again_to_exit">再按一次退出程序</string>

autojs/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ dependencies {
5050
api('com.afollestad.material-dialogs:core:0.9.2.3', {
5151
exclude group: 'com.android.support'
5252
})
53-
api 'com.google.android.material:material:1.1.0-alpha01'
53+
api 'com.google.android.material:material:1.3.0-alpha02'
5454
api 'com.github.hyb1996:EnhancedFloaty:0.31'
5555
api 'com.makeramen:roundedimageview:2.3.0'
5656
// OpenCv

build.gradle

+3-3
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,15 @@ import groovy.json.JsonSlurper
44

55

66
buildscript {
7-
ext.kotlin_version = '1.3.10'
7+
ext.kotlin_version = '1.3.70'
88
repositories {
99
google()
1010
jcenter()
1111
}
1212
dependencies {
13-
classpath 'com.android.tools.build:gradle:3.2.1'
13+
classpath 'com.android.tools.build:gradle:4.0.1'
1414
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
15-
classpath 'com.jakewharton:butterknife-gradle-plugin:9.0.0-rc2'
15+
classpath 'com.jakewharton:butterknife-gradle-plugin:10.2.1'
1616

1717
}
1818
}

common/build.gradle

-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ android {
1111
targetSdkVersion versions.target
1212
versionCode 1
1313
versionName "1.0"
14-
1514
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
1615

1716
}

gradle.properties

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
# Specifies the JVM arguments used for the daemon process.
77
# The setting is particularly useful for tweaking memory settings.
88
# Default value: -Xmx1024m -XX:MaxPermSize=256m
9-
# org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8
9+
org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8
1010
#
1111
# When configured, Gradle will run in incubating parallel mode.
1212
# This option should only be used with decoupled projects. More details, visit
@@ -15,7 +15,7 @@
1515
#Mon Jan 23 10:16:46 CST 2017
1616
#systemProp.https.proxyPort=1080
1717
#systemProp.http.proxyHost=127.0.0.1
18-
org.gradle.jvmargs=-Xms2192m -Xmx2192m -Dfile.encoding=UTF-8
18+
#org.gradle.jvmargs=-Xms4192m -Xmx2192m -Dfile.encoding=UTF-8
1919
#systemProp.https.proxyHost=127.0.0.1
2020
#systemProp.http.proxyPort=1080
2121
android.useAndroidX=true
+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
#Sun Sep 13 16:26:07 CST 2020
1+
#Mon Sep 14 18:07:46 CST 2020
22
distributionBase=GRADLE_USER_HOME
33
distributionPath=wrapper/dists
44
zipStoreBase=GRADLE_USER_HOME
55
zipStorePath=wrapper/dists
6-
distributionUrl=https\://services.gradle.org/distributions/gradle-4.10.2-all.zip
6+
distributionUrl=https\://services.gradle.org/distributions/gradle-6.1.1-all.zip

project-versions.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,5 @@
44
"target": 28,
55
"mini": 17,
66
"compile": 28,
7-
"buildTool": "28.0.3"
7+
"buildTool": "29.0.2"
88
}

0 commit comments

Comments
 (0)