From c0aff08ef788baa4777544c3d5dd986740375c4a Mon Sep 17 00:00:00 2001 From: gedoor Date: Mon, 18 Oct 2021 21:28:08 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/build.gradle | 5 +++-- .../java/com/kunfei/bookshelf/help/coroutine/Coroutine.kt | 7 ++----- 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/app/build.gradle b/app/build.gradle index 68c7bdbf3..e844ddd43 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -85,7 +85,7 @@ dependencies { testImplementation 'junit:junit:4.13.2' implementation fileTree(dir: 'libs', include: ['*.jar']) implementation project(':basemvplib') - + implementation('androidx.multidex:multidex:2.0.1') implementation("org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version") implementation "org.jetbrains.kotlin:kotlin-reflect:$kotlin_version" @@ -123,6 +123,8 @@ dependencies { implementation("com.louiscad.splitties:splitties-systemservices:$splitties_version") implementation("com.louiscad.splitties:splitties-views:$splitties_version") + //media + implementation("androidx.media:media:1.4.1") def exoplayer_version = '2.15.0' implementation "com.google.android.exoplayer:exoplayer-core:$exoplayer_version" implementation "com.google.android.exoplayer:extension-okhttp:$exoplayer_version" @@ -134,7 +136,6 @@ dependencies { //google implementation 'com.google.android.material:material:1.4.0' implementation 'com.google.code.gson:gson:2.8.8' - implementation 'com.google.android:flexbox:1.1.0' //RxAndroid implementation 'io.reactivex.rxjava2:rxjava:2.2.19' diff --git a/app/src/main/java/com/kunfei/bookshelf/help/coroutine/Coroutine.kt b/app/src/main/java/com/kunfei/bookshelf/help/coroutine/Coroutine.kt index d12a053b6..490c9784c 100644 --- a/app/src/main/java/com/kunfei/bookshelf/help/coroutine/Coroutine.kt +++ b/app/src/main/java/com/kunfei/bookshelf/help/coroutine/Coroutine.kt @@ -1,8 +1,7 @@ package io.legado.app.help.coroutine -import io.legado.app.BuildConfig -import io.legado.app.utils.printOnDebug import kotlinx.coroutines.* +import timber.log.Timber import kotlin.coroutines.CoroutineContext @@ -143,9 +142,7 @@ class Coroutine( success?.let { dispatchCallback(this, value, it) } } } catch (e: Throwable) { - if (BuildConfig.DEBUG) { - e.printOnDebug() - } + Timber.e(e) val consume: Boolean = errorReturn?.value?.let { value -> if (isActive) { success?.let { dispatchCallback(this, value, it) }