From a7505a6c5e94b1938783c8848379cc0edb29ddeb Mon Sep 17 00:00:00 2001 From: ag2s20150909 Date: Sun, 3 Jul 2022 11:40:53 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0kotlin=E7=89=88=E6=9C=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 更新kotlin 1.7.0 更新Compose 1.2.0 更新room 2.5.0-alpha02 旧版本不支持kotlin 1.7.0 --- app/build.gradle | 17 +++++++++-------- .../legado/app/ui/rss/read/ReadRssViewModel.kt | 1 + build.gradle | 7 ++++++- 3 files changed, 16 insertions(+), 9 deletions(-) diff --git a/app/build.gradle b/app/build.gradle index 1ae648a03..416890b2a 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -110,7 +110,7 @@ android { targetCompatibility JavaVersion.VERSION_11 } composeOptions { - kotlinCompilerExtensionVersion '1.1.1' + kotlinCompilerExtensionVersion "$compose_compiler_version" } sourceSets { @@ -180,31 +180,32 @@ dependencies { // Integration with activities implementation 'androidx.activity:activity-compose:1.5.0' // Compose Material Design - implementation 'androidx.compose.material:material:1.1.1' + implementation "androidx.compose.material:material:$compose_version" // Animations - implementation 'androidx.compose.animation:animation:1.1.1' + implementation "androidx.compose.animation:animation:$compose_version" // Tooling support (Previews, etc.) - implementation 'androidx.compose.ui:ui-tooling:1.1.1' + implementation "androidx.compose.ui:ui-tooling:$compose_version" // UI Tests - androidTestImplementation 'androidx.compose.ui:ui-test-junit4:1.1.1' + androidTestImplementation "androidx.compose.ui:ui-test-junit4:$compose_version" //media implementation("androidx.media:media:1.6.0") - def exoplayer_version = '2.18.0' + + implementation("com.google.android.exoplayer:exoplayer-core:$exoplayer_version") implementation("com.google.android.exoplayer:extension-okhttp:$exoplayer_version") //Splitties - def splitties_version = '3.0.0' + implementation("com.louiscad.splitties:splitties-appctx:$splitties_version") implementation("com.louiscad.splitties:splitties-systemservices:$splitties_version") implementation("com.louiscad.splitties:splitties-views:$splitties_version") //room - def room_version = '2.4.2' implementation("androidx.room:room-runtime:$room_version") implementation("androidx.room:room-ktx:$room_version") kapt("androidx.room:room-compiler:$room_version") + //ksp("androidx.room:room-compiler:$room_version") testImplementation("androidx.room:room-testing:$room_version") //liveEventBus diff --git a/app/src/main/java/io/legado/app/ui/rss/read/ReadRssViewModel.kt b/app/src/main/java/io/legado/app/ui/rss/read/ReadRssViewModel.kt index 8b1941666..dd1f18116 100644 --- a/app/src/main/java/io/legado/app/ui/rss/read/ReadRssViewModel.kt +++ b/app/src/main/java/io/legado/app/ui/rss/read/ReadRssViewModel.kt @@ -240,6 +240,7 @@ class ReadRssViewModel(application: Application) : BaseViewModel(application), callBack?.upTtsMenu(false) } + @Deprecated("Deprecated in Java") override fun onError(s: String) { } diff --git a/build.gradle b/build.gradle index 3aba05806..184910e1e 100644 --- a/build.gradle +++ b/build.gradle @@ -2,8 +2,13 @@ buildscript { ext{ - kotlin_version = '1.6.10' + kotlin_version = '1.7.0' + compose_version = '1.2.0-rc03' + compose_compiler_version = '1.2.0' agp_version= '7.2.1' + exoplayer_version = '2.18.0' + splitties_version = '3.0.0' + room_version = '2.5.0-alpha02' } }