From 717cfd08b51ab0abb21d1d9d5cca098967951143 Mon Sep 17 00:00:00 2001 From: Steven Zeck <8315038+stevenzeck@users.noreply.github.com> Date: Mon, 4 Nov 2024 06:30:48 -0600 Subject: [PATCH] Dependency updates (#576) --- .github/workflows/checks.yml | 14 ++--- README.md | 9 +-- gradle/libs.versions.toml | 61 ++++++++----------- gradle/wrapper/gradle-wrapper.properties | 2 +- .../exoplayer/audio/ExoPlayerEngine.kt | 6 +- .../adapters/pdfium/document/build.gradle.kts | 6 -- .../pdfium/navigator/build.gradle.kts | 5 -- .../pspdfkit/document/build.gradle.kts | 6 -- .../pspdfkit/navigator/build.gradle.kts | 5 -- readium/lcp/build.gradle.kts | 3 - readium/navigator-media2/build.gradle.kts | 3 - readium/navigator/build.gradle.kts | 9 +-- .../navigators/media/audio/build.gradle.kts | 1 - .../navigator/media/tts/TtsEngineFacade.kt | 4 +- readium/opds/build.gradle.kts | 6 -- readium/shared/build.gradle.kts | 6 +- readium/streamer/build.gradle.kts | 9 --- test-app/build.gradle.kts | 15 ++--- .../readium/r2/testapp/reader/MediaService.kt | 2 +- .../r2/testapp/utils/extensions/Flow.kt | 2 +- 20 files changed, 51 insertions(+), 123 deletions(-) diff --git a/.github/workflows/checks.yml b/.github/workflows/checks.yml index e0be883ca7..e543e1eec5 100644 --- a/.github/workflows/checks.yml +++ b/.github/workflows/checks.yml @@ -13,9 +13,9 @@ jobs: if: ${{ !github.event.pull_request.draft }} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Set up JDK 17 - uses: actions/setup-java@v3 + uses: actions/setup-java@v4 with: java-version: '17' distribution: 'adopt' @@ -30,9 +30,9 @@ jobs: if: ${{ !github.event.pull_request.draft }} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Set up JDK 17 - uses: actions/setup-java@v3 + uses: actions/setup-java@v4 with: java-version: '17' distribution: 'adopt' @@ -47,14 +47,14 @@ jobs: scripts: ${{ 'readium/navigator/src/main/assets/_scripts' }} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install pnpm - uses: pnpm/action-setup@v2 + uses: pnpm/action-setup@v4 with: package_json_file: readium/navigator/src/main/assets/_scripts/package.json run_install: false - name: Setup cache - uses: actions/setup-node@v3 + uses: actions/setup-node@v4 with: node-version: 20 cache: 'pnpm' diff --git a/README.md b/README.md index 3ea49e73fa..575022a327 100644 --- a/README.md +++ b/README.md @@ -8,10 +8,11 @@ ## Minimum Requirements -| Readium | Android min SDK | Android compile SDK | Kotlin compiler (✻) | Gradle (✻) | -|---------|-----------------|---------------------|---------------------|------------| -| 3.0.0 | 21 | 34 | 1.9.24 | 8.6.0 | -| 2.3.0 | 21 | 33 | 1.7.10 | 6.9.3 | +| Readium | Android min SDK | Android compile SDK | Kotlin compiler (✻) | Gradle (✻) | +|-----------|-----------------|---------------------|---------------------|------------| +| `develop` | 21 | 34 | 1.9.24 | 8.10.2 | +| 3.0.0 | 21 | 34 | 1.9.24 | 8.6.0 | +| 2.3.0 | 21 | 33 | 1.7.10 | 6.9.3 | ✻ Only required if you integrate Readium as a submodule instead of using Maven Central. diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 611a710205..38d7ee0596 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -1,56 +1,54 @@ [versions] kotlin = "1.9.24" -agp = "8.4.0" +agp = "8.7.2" desugar_jdk_libs = "2.0.4" gradle-maven-publish-plugin = "0.28.0" -androidx-activity = "1.9.0" -androidx-appcompat = "1.6.1" +androidx-activity = "1.9.3" +androidx-annotation = "1.9.1" +androidx-appcompat = "1.7.0" androidx-browser = "1.8.0" androidx-cardview = "1.0.0" # Make sure to align with the Kotlin version # https://developer.android.com/jetpack/androidx/releases/compose-kotlin androidx-compose-compiler = "1.5.14" -androidx-compose-animation = "1.6.7" -androidx-compose-foundation = "1.6.7" -androidx-compose-material = "1.6.7" -androidx-compose-material3 = "1.2.1" -androidx-compose-runtime = "1.6.7" -androidx-compose-ui = "1.6.7" -androidx-constraintlayout = "2.1.4" +androidx-compose-animation = "1.7.5" +androidx-compose-foundation = "1.7.5" +androidx-compose-material = "1.7.5" +androidx-compose-material3 = "1.3.1" +androidx-compose-runtime = "1.7.5" +androidx-compose-ui = "1.7.5" +androidx-constraintlayout = "2.2.0" androidx-core = "1.13.1" androidx-datastore = "1.1.1" -androidx-expresso-core = "3.5.1" -androidx-ext-junit = "1.1.5" -androidx-fragment-ktx = "1.7.1" +androidx-fragment-ktx = "1.8.5" androidx-legacy = "1.0.0" -androidx-lifecycle = "2.8.0" -androidx-lifecycle-extensions = "2.2.0" +androidx-lifecycle = "2.8.7" androidx-media = "1.7.0" androidx-media2 = "1.3.0" -androidx-media3 = "1.3.1" -androidx-navigation = "2.7.7" -androidx-paging = "3.3.0" +androidx-media3 = "1.4.1" +androidx-navigation = "2.8.3" +androidx-paging = "3.3.2" androidx-recyclerview = "1.3.2" androidx-room = "2.6.1" androidx-viewpager2 = "1.1.0" -androidx-webkit = "1.11.0" +androidx-webkit = "1.12.1" -assertj = "3.25.3" +assertj = "3.26.3" dokka = "1.9.20" google-exoplayer = "2.19.1" google-material = "1.12.0" -joda-time = "2.12.7" -jsoup = "1.17.2" +joda-time = "2.13.0" +jsoup = "1.18.1" junit = "4.13.2" -kotlinx-coroutines = "1.8.1" -kotlinx-coroutines-test = "1.8.1" -kotlinx-datetime = "0.6.0" +kotlinx-coroutines = "1.9.0" +kotlinx-coroutines-test = "1.9.0" +kotlinx-datetime = "0.6.1" kotlinx-serialization-json = "1.6.3" # Make sure to align with the Kotlin version. @@ -68,7 +66,7 @@ pdf-viewer = "2.8.2" picasso = "2.8" pspdfkit = "8.4.1" -robolectric = "4.12.2" +robolectric = "4.13" timber = "5.0.1" @@ -76,6 +74,7 @@ timber = "5.0.1" [libraries] androidx-activity-ktx = { group = "androidx.activity", name = "activity-ktx", version.ref = "androidx-activity" } +androidx-annotation = { group = "androidx.annotation", name = "annotation", version.ref = "androidx-annotation" } androidx-appcompat = { group = "androidx.appcompat", name = "appcompat", version.ref = "androidx-appcompat" } androidx-browser = { group = "androidx.browser", name = "browser", version.ref = "androidx-browser" } androidx-cardview = { group = "androidx.cardview", name = "cardview", version.ref = "androidx-cardview" } @@ -91,18 +90,9 @@ androidx-compose-ui-tooling = { group = "androidx.compose.ui", name = "ui-toolin androidx-constraintlayout = { group = "androidx.constraintlayout", name = "constraintlayout", version.ref = "androidx-constraintlayout" } androidx-core = { group = "androidx.core", name = "core-ktx", version.ref = "androidx-core" } androidx-datastore-preferences = { group = "androidx.datastore", name = "datastore-preferences", version.ref = "androidx-datastore" } -androidx-expresso-core = { group = "androidx.test.espresso", name = "espresso-core", version.ref = "androidx-expresso-core" } -androidx-ext-junit = { group = "androidx.test.ext", name = "junit", version.ref = "androidx-ext-junit" } androidx-fragment-ktx = { group = "androidx.fragment", name = "fragment-ktx", version.ref = "androidx-fragment-ktx" } -androidx-legacy-v4 = { group = "androidx.legacy", name = "legacy-support-v4", version.ref = "androidx-legacy" } androidx-legacy-ui = { group = "androidx.legacy", name = "legacy-support-core-ui", version.ref = "androidx-legacy" } androidx-lifecycle-common = { group = "androidx.lifecycle", name = "lifecycle-common-java8", version.ref = "androidx-lifecycle" } -androidx-lifecycle-extensions = { group = "androidx.lifecycle", name = "lifecycle-extensions", version.ref = "androidx-lifecycle-extensions" } -androidx-lifecycle-livedata = { group = "androidx.lifecycle", name = "lifecycle-livedata-ktx", version.ref = "androidx-lifecycle" } -androidx-lifecycle-runtime = { group = "androidx.lifecycle", name = "lifecycle-runtime-ktx", version.ref = "androidx-lifecycle" } -androidx-lifecycle-viewmodel = { group = "androidx.lifecycle", name = "lifecycle-viewmodel-ktx", version.ref = "androidx-lifecycle" } -androidx-lifecycle-viewmodel-compose = { group = "androidx.lifecycle", name = "lifecycle-viewmodel-compose", version.ref = "androidx-lifecycle" } -androidx-lifecycle-vmsavedstate = { group = "androidx.lifecycle", name = "lifecycle-viewmodel-savedstate", version.ref = "androidx-lifecycle" } androidx-media = { group = "androidx.media", name = "media", version.ref = "androidx-media" } androidx-media2-session = { group = "androidx.media2", name = "media2-session", version.ref = "androidx-media2" } androidx-media2-player = { group = "androidx.media2", name = "media2-player", version.ref = "androidx-media2" } @@ -165,7 +155,6 @@ ktlint = { id = "org.jlleitschuh.gradle.ktlint", version.ref = "ktlint" } compose = ["androidx-compose-activity", "androidx-compose-animation", "androidx-compose-foundation", "androidx-compose-material", "androidx-compose-material3", "androidx-compose-material-icons", "androidx-compose-runtime", "androidx-compose-ui", "androidx-compose-ui-tooling"] exoplayer = ["google-exoplayer-core", "google-exoplayer-ui", "google-exoplayer-mediasession", "google-exoplayer-workmanager", "google-exoplayer-extension-media2"] -lifecycle = ["androidx-lifecycle-common", "androidx-lifecycle-extensions", "androidx-lifecycle-livedata", "androidx-lifecycle-runtime", "androidx-lifecycle-viewmodel", "androidx-lifecycle-vmsavedstate", "androidx-lifecycle-viewmodel-compose"] media2 = ["androidx-media2-session", "androidx-media2-player", "google-exoplayer-core", "google-exoplayer-extension-media2"] media3 = ["androidx-media3-session", "androidx-media3-common", "androidx-media3-exoplayer"] room = ["androidx-room-runtime", "androidx-room-ktx"] diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 17655d0ef2..1e2fbf0d45 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-8.6-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-8.10.2-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/readium/adapters/exoplayer/audio/src/main/java/org/readium/adapter/exoplayer/audio/ExoPlayerEngine.kt b/readium/adapters/exoplayer/audio/src/main/java/org/readium/adapter/exoplayer/audio/ExoPlayerEngine.kt index 94cd4beb57..e048da9682 100644 --- a/readium/adapters/exoplayer/audio/src/main/java/org/readium/adapter/exoplayer/audio/ExoPlayerEngine.kt +++ b/readium/adapters/exoplayer/audio/src/main/java/org/readium/adapter/exoplayer/audio/ExoPlayerEngine.kt @@ -120,13 +120,13 @@ public class ExoPlayerEngine private constructor( private suspend fun prepareExoPlayer(player: ExoPlayer) { lateinit var listener: Player.Listener - suspendCancellableCoroutine { continuation -> + suspendCancellableCoroutine { continuation -> listener = object : Player.Listener { override fun onPlaybackStateChanged(playbackState: Int) { when (playbackState) { - Player.STATE_READY -> continuation.resume(Unit) {} + Player.STATE_READY -> continuation.resume(Unit) { _, _, _ -> } Player.STATE_IDLE -> if (player.playerError != null) { - continuation.resume(Unit) {} + continuation.resume(Unit) { _, _, _ -> } } else -> {} } diff --git a/readium/adapters/pdfium/document/build.gradle.kts b/readium/adapters/pdfium/document/build.gradle.kts index 93b145f568..d1eab7034c 100644 --- a/readium/adapters/pdfium/document/build.gradle.kts +++ b/readium/adapters/pdfium/document/build.gradle.kts @@ -15,13 +15,7 @@ android { dependencies { api(project(":readium:readium-shared")) - implementation(libs.androidx.core) implementation(libs.pdfium) implementation(libs.timber) implementation(libs.kotlinx.coroutines.android) - - testImplementation(libs.junit) - - androidTestImplementation(libs.androidx.ext.junit) - androidTestImplementation(libs.androidx.expresso.core) } diff --git a/readium/adapters/pdfium/navigator/build.gradle.kts b/readium/adapters/pdfium/navigator/build.gradle.kts index 8a30470160..8243f6d3c6 100644 --- a/readium/adapters/pdfium/navigator/build.gradle.kts +++ b/readium/adapters/pdfium/navigator/build.gradle.kts @@ -28,9 +28,4 @@ dependencies { implementation(libs.timber) implementation(libs.kotlinx.coroutines.android) implementation(libs.kotlinx.serialization.json) - - testImplementation(libs.junit) - - androidTestImplementation(libs.androidx.ext.junit) - androidTestImplementation(libs.androidx.expresso.core) } diff --git a/readium/adapters/pspdfkit/document/build.gradle.kts b/readium/adapters/pspdfkit/document/build.gradle.kts index bbfbaadbd9..74cddccd99 100644 --- a/readium/adapters/pspdfkit/document/build.gradle.kts +++ b/readium/adapters/pspdfkit/document/build.gradle.kts @@ -15,13 +15,7 @@ android { dependencies { api(project(":readium:readium-shared")) - implementation(libs.androidx.core) implementation(libs.timber) implementation(libs.pspdfkit) implementation(libs.kotlinx.coroutines.android) - - testImplementation(libs.junit) - - androidTestImplementation(libs.androidx.ext.junit) - androidTestImplementation(libs.androidx.expresso.core) } diff --git a/readium/adapters/pspdfkit/navigator/build.gradle.kts b/readium/adapters/pspdfkit/navigator/build.gradle.kts index 67f4dd44e8..34f1b27a23 100644 --- a/readium/adapters/pspdfkit/navigator/build.gradle.kts +++ b/readium/adapters/pspdfkit/navigator/build.gradle.kts @@ -26,9 +26,4 @@ dependencies { implementation(libs.pspdfkit) implementation(libs.kotlinx.coroutines.android) implementation(libs.kotlinx.serialization.json) - - testImplementation(libs.junit) - - androidTestImplementation(libs.androidx.ext.junit) - androidTestImplementation(libs.androidx.expresso.core) } diff --git a/readium/lcp/build.gradle.kts b/readium/lcp/build.gradle.kts index 8a2aec53ef..f7bb85f947 100644 --- a/readium/lcp/build.gradle.kts +++ b/readium/lcp/build.gradle.kts @@ -37,7 +37,4 @@ dependencies { // Tests testImplementation(libs.junit) testImplementation(libs.kotlin.junit) - - androidTestImplementation(libs.androidx.ext.junit) - androidTestImplementation(libs.androidx.expresso.core) } diff --git a/readium/navigator-media2/build.gradle.kts b/readium/navigator-media2/build.gradle.kts index eb8d371d5d..c1c4acc55e 100644 --- a/readium/navigator-media2/build.gradle.kts +++ b/readium/navigator-media2/build.gradle.kts @@ -27,7 +27,4 @@ dependencies { implementation(libs.bundles.media2) testImplementation(libs.junit) - - androidTestImplementation(libs.androidx.ext.junit) - androidTestImplementation(libs.androidx.expresso.core) } diff --git a/readium/navigator/build.gradle.kts b/readium/navigator/build.gradle.kts index 4f126d7141..54310f3481 100644 --- a/readium/navigator/build.gradle.kts +++ b/readium/navigator/build.gradle.kts @@ -22,27 +22,22 @@ dependencies { implementation(files("libs/PhotoView-2.3.0.jar")) - implementation(libs.androidx.activity.ktx) implementation(libs.androidx.appcompat) implementation(libs.androidx.browser) implementation(libs.androidx.constraintlayout) implementation(libs.androidx.core) implementation(libs.androidx.fragment.ktx) implementation(libs.androidx.legacy.ui) - implementation(libs.androidx.legacy.v4) - implementation(libs.bundles.lifecycle) + implementation(libs.androidx.lifecycle.common) implementation(libs.androidx.recyclerview) implementation(libs.androidx.media) implementation(libs.bundles.media3) - implementation(libs.androidx.viewpager2) implementation(libs.androidx.webkit) implementation(libs.bundles.media2) // ExoPlayer is used by the Audio Navigator. api(libs.bundles.exoplayer) - implementation(libs.google.material) implementation(libs.timber) - implementation(libs.joda.time) implementation(libs.kotlinx.coroutines.android) implementation(libs.kotlinx.serialization.json) implementation(libs.jsoup) @@ -50,8 +45,6 @@ dependencies { // Tests testImplementation(libs.junit) - androidTestImplementation(libs.androidx.ext.junit) - androidTestImplementation(libs.androidx.expresso.core) testImplementation(libs.kotlin.junit) testImplementation(libs.kotlinx.coroutines.test) testImplementation(libs.robolectric) diff --git a/readium/navigators/media/audio/build.gradle.kts b/readium/navigators/media/audio/build.gradle.kts index cb5f55932d..b65100f7df 100644 --- a/readium/navigators/media/audio/build.gradle.kts +++ b/readium/navigators/media/audio/build.gradle.kts @@ -22,7 +22,6 @@ dependencies { implementation(libs.androidx.media3.common) implementation(libs.androidx.media3.session) - implementation(libs.androidx.core) implementation(libs.timber) implementation(libs.kotlinx.coroutines.android) } diff --git a/readium/navigators/media/tts/src/main/java/org/readium/navigator/media/tts/TtsEngineFacade.kt b/readium/navigators/media/tts/src/main/java/org/readium/navigator/media/tts/TtsEngineFacade.kt index e96eaadada..5b849f87cc 100644 --- a/readium/navigators/media/tts/src/main/java/org/readium/navigator/media/tts/TtsEngineFacade.kt +++ b/readium/navigators/media/tts/src/main/java/org/readium/navigator/media/tts/TtsEngineFacade.kt @@ -76,11 +76,11 @@ internal class TtsEngineFacade } } override fun onError(requestId: TtsEngine.RequestId, error: E) { - popTask(requestId)?.continuation?.resume(error) {} + popTask(requestId)?.continuation?.resume(error) { _, _, _ -> } } } } diff --git a/readium/opds/build.gradle.kts b/readium/opds/build.gradle.kts index 5a8d26219a..a65810aac4 100644 --- a/readium/opds/build.gradle.kts +++ b/readium/opds/build.gradle.kts @@ -15,16 +15,10 @@ android { dependencies { api(project(":readium:readium-shared")) - implementation(libs.androidx.appcompat) implementation(libs.timber) - implementation(libs.joda.time) implementation(libs.kotlinx.coroutines.android) // Tests testImplementation(libs.junit) - - androidTestImplementation(libs.androidx.ext.junit) - androidTestImplementation(libs.androidx.expresso.core) - testImplementation(libs.robolectric) } diff --git a/readium/shared/build.gradle.kts b/readium/shared/build.gradle.kts index bc31c9a0ab..ee22eadb29 100644 --- a/readium/shared/build.gradle.kts +++ b/readium/shared/build.gradle.kts @@ -14,8 +14,7 @@ android { } dependencies { - implementation(libs.androidx.appcompat) - implementation(libs.androidx.browser) + implementation(libs.androidx.annotation) implementation(libs.timber) implementation(libs.kotlin.reflect) implementation(libs.kotlinx.coroutines.android) @@ -26,9 +25,6 @@ dependencies { // Tests testImplementation(libs.junit) - androidTestImplementation(libs.androidx.ext.junit) - androidTestImplementation(libs.androidx.expresso.core) - testImplementation(libs.assertj) testImplementation(libs.kotlin.junit) testImplementation(libs.kotlinx.coroutines.test) diff --git a/readium/streamer/build.gradle.kts b/readium/streamer/build.gradle.kts index 506d0951b5..2493ff3b0b 100644 --- a/readium/streamer/build.gradle.kts +++ b/readium/streamer/build.gradle.kts @@ -17,26 +17,17 @@ dependencies { api(files("libs/nanohttpd-2.3.2.jar", "libs/nanohttpd-nanolets-2.3.2.jar")) - implementation(libs.androidx.appcompat) @Suppress("GradleDependency") implementation(libs.timber) // AM NOTE: conflicting support libraries, excluding these implementation("com.mcxiaoke.koi:core:0.5.5") { exclude(module = "support-v4") } - // useful extensions (only ~100k) - implementation("com.mcxiaoke.koi:async:0.5.5") { - exclude(module = "support-v4") - } - implementation(libs.joda.time) implementation(libs.kotlinx.coroutines.android) // Tests testImplementation(libs.junit) testImplementation(libs.kotlin.junit) - - androidTestImplementation(libs.androidx.ext.junit) - androidTestImplementation(libs.androidx.expresso.core) testImplementation(libs.assertj) testImplementation(libs.robolectric) } diff --git a/test-app/build.gradle.kts b/test-app/build.gradle.kts index 826674c651..d8d2f6df30 100644 --- a/test-app/build.gradle.kts +++ b/test-app/build.gradle.kts @@ -12,10 +12,10 @@ plugins { } android { - compileSdk = 34 + compileSdk = (property("android.compileSdk") as String).toInt() defaultConfig { - minSdk = 21 - targetSdk = 34 + minSdk = (property("android.minSdk") as String).toInt() + targetSdk = (property("android.targetSdk") as String).toInt() applicationId = "org.readium.r2reader" @@ -69,7 +69,6 @@ dependencies { coreLibraryDesugaring(libs.desugar.jdk.libs) implementation(libs.kotlin.stdlib) - implementation(libs.androidx.legacy.v4) implementation(project(":readium:readium-shared")) implementation(project(":readium:readium-streamer")) @@ -96,7 +95,7 @@ dependencies { implementation(libs.androidx.core) implementation(libs.androidx.datastore.preferences) implementation(libs.androidx.fragment.ktx) - implementation(libs.bundles.lifecycle) + implementation(libs.androidx.lifecycle.common) implementation(libs.androidx.navigation.fragment) implementation(libs.androidx.navigation.ui) implementation(libs.androidx.paging) @@ -115,10 +114,4 @@ dependencies { // Room database implementation(libs.bundles.room) ksp(libs.androidx.room.compiler) - - // Tests - testImplementation(libs.junit) - - androidTestImplementation(libs.androidx.ext.junit) - androidTestImplementation(libs.androidx.expresso.core) } diff --git a/test-app/src/main/java/org/readium/r2/testapp/reader/MediaService.kt b/test-app/src/main/java/org/readium/r2/testapp/reader/MediaService.kt index e3eaaeaf43..fc51c220ba 100644 --- a/test-app/src/main/java/org/readium/r2/testapp/reader/MediaService.kt +++ b/test-app/src/main/java/org/readium/r2/testapp/reader/MediaService.kt @@ -171,7 +171,7 @@ class MediaService : MediaSessionService() { return binder.session.value?.mediaSession } - override fun onTaskRemoved(rootIntent: Intent) { + override fun onTaskRemoved(rootIntent: Intent?) { super.onTaskRemoved(rootIntent) Timber.d("Task removed. Stopping session and service.") // Close the session to allow the service to be stopped. diff --git a/test-app/src/main/java/org/readium/r2/testapp/utils/extensions/Flow.kt b/test-app/src/main/java/org/readium/r2/testapp/utils/extensions/Flow.kt index 1d2f058aae..c160eacebd 100644 --- a/test-app/src/main/java/org/readium/r2/testapp/utils/extensions/Flow.kt +++ b/test-app/src/main/java/org/readium/r2/testapp/utils/extensions/Flow.kt @@ -10,7 +10,7 @@ import androidx.compose.runtime.Composable import androidx.compose.runtime.State import androidx.compose.runtime.collectAsState import androidx.compose.runtime.remember -import androidx.compose.ui.platform.LocalLifecycleOwner +import androidx.lifecycle.compose.LocalLifecycleOwner import androidx.lifecycle.flowWithLifecycle import kotlin.time.Duration import kotlinx.coroutines.CoroutineScope