From a33f10b9d57e29fdcede62a3fbbc3b7ae8d0c4ed Mon Sep 17 00:00:00 2001 From: Vladimir Raupov Date: Thu, 15 Sep 2022 23:12:38 +0300 Subject: [PATCH 1/3] dependencies update --- .../main/kotlin/LibraryConventionPlugin.kt | 5 +++- .../corbind/Project+configureKotlinAndroid.kt | 8 +++-- build.gradle.kts | 3 +- corbind-activity/README.md | 2 +- corbind-activity/build.gradle.kts | 6 +++- corbind-activity/src/main/AndroidManifest.xml | 2 +- .../OnBackPressedDispatcherBackPresses.kt | 30 +++++++++---------- corbind-appcompat/build.gradle.kts | 6 +++- .../src/main/AndroidManifest.xml | 2 +- corbind-core/build.gradle.kts | 6 +++- corbind-core/src/main/AndroidManifest.xml | 2 +- corbind-drawerlayout/build.gradle.kts | 6 +++- .../src/main/AndroidManifest.xml | 2 +- corbind-leanback/build.gradle.kts | 6 +++- corbind-leanback/src/main/AndroidManifest.xml | 3 +- corbind-lifecycle/build.gradle.kts | 6 +++- .../src/main/AndroidManifest.xml | 2 +- corbind-material/build.gradle.kts | 6 +++- corbind-material/src/main/AndroidManifest.xml | 2 +- corbind-navigation/build.gradle.kts | 6 +++- .../src/main/AndroidManifest.xml | 2 +- corbind-recyclerview/build.gradle.kts | 6 +++- .../src/main/AndroidManifest.xml | 2 +- corbind-slidingpanelayout/build.gradle.kts | 6 +++- .../src/main/AndroidManifest.xml | 2 +- corbind-swiperefreshlayout/build.gradle.kts | 6 +++- .../src/main/AndroidManifest.xml | 2 +- corbind-viewpager/build.gradle.kts | 6 +++- .../src/main/AndroidManifest.xml | 2 +- corbind-viewpager2/build.gradle.kts | 6 +++- .../src/main/AndroidManifest.xml | 2 +- corbind/build.gradle.kts | 4 +++ corbind/src/main/AndroidManifest.xml | 2 +- gradle.properties | 6 ++-- gradle/libs.versions.toml | 26 ++++++++-------- gradle/wrapper/gradle-wrapper.properties | 2 +- sample/build.gradle.kts | 17 +++++++---- sample/src/main/AndroidManifest.xml | 9 ++---- 38 files changed, 144 insertions(+), 75 deletions(-) diff --git a/build-logic/convention/src/main/kotlin/LibraryConventionPlugin.kt b/build-logic/convention/src/main/kotlin/LibraryConventionPlugin.kt index bf84acc8..93c46daf 100644 --- a/build-logic/convention/src/main/kotlin/LibraryConventionPlugin.kt +++ b/build-logic/convention/src/main/kotlin/LibraryConventionPlugin.kt @@ -18,6 +18,7 @@ import com.android.build.gradle.LibraryExtension import org.gradle.api.Plugin import org.gradle.api.Project import org.gradle.kotlin.dsl.configure +import org.gradle.kotlin.dsl.provideDelegate import ru.ldralighieri.corbind.configureKotlinAndroid @Suppress("unused") @@ -32,8 +33,10 @@ class LibraryConventionPlugin : Plugin { } extensions.configure { + val targetSdk: String by project + configureKotlinAndroid(this) - defaultConfig.targetSdk = findProperty("android.targetSdk").toString().toInt() + defaultConfig.targetSdk = targetSdk.toInt() buildTypes { release { diff --git a/build-logic/convention/src/main/kotlin/ru/ldralighieri/corbind/Project+configureKotlinAndroid.kt b/build-logic/convention/src/main/kotlin/ru/ldralighieri/corbind/Project+configureKotlinAndroid.kt index be509a87..b5c61ab3 100644 --- a/build-logic/convention/src/main/kotlin/ru/ldralighieri/corbind/Project+configureKotlinAndroid.kt +++ b/build-logic/convention/src/main/kotlin/ru/ldralighieri/corbind/Project+configureKotlinAndroid.kt @@ -22,16 +22,20 @@ import com.android.build.api.dsl.CommonExtension import org.gradle.api.JavaVersion import org.gradle.api.Project import org.gradle.api.plugins.ExtensionAware +import org.gradle.kotlin.dsl.provideDelegate import org.jetbrains.kotlin.gradle.dsl.KotlinJvmOptions internal fun Project.configureKotlinAndroid( commonExtension: CommonExtension<*, *, *, *>, ) { + val compileSdk: String by project + val minSdk: String by project + commonExtension.apply { - compileSdk = findProperty("android.compileSdk").toString().toInt() + this.compileSdk = compileSdk.toInt() defaultConfig { - minSdk = findProperty("android.minSdk").toString().toInt() + this.minSdk = minSdk.toInt() } compileOptions { diff --git a/build.gradle.kts b/build.gradle.kts index f731a100..40c473e2 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -65,8 +65,7 @@ tasks.withType().configureEach { // Dependency updates fun isNonStable(version: String): Boolean { - val stableKeyword = listOf("RELEASE", "FINAL") - .any { version.toUpperCase().contains(it) } + val stableKeyword = listOf("RELEASE", "FINAL").any { version.toUpperCase().contains(it) } val regex = "^[0-9,.v-]+(-r)?$".toRegex() val isStable = stableKeyword || regex.matches(version) return isStable.not() diff --git a/corbind-activity/README.md b/corbind-activity/README.md index 03c85458..ee06a608 100644 --- a/corbind-activity/README.md +++ b/corbind-activity/README.md @@ -17,7 +17,7 @@ Component | Extension | Description ## Simple examples ```kotlin -requireActivity().onBackPressedDispatcher.backPresses() +onBackPressedDispatcher.backPresses(lifecycleOwner = this) .onEach { /* handle onBackPressed event */ } .flowWithLifecycle(lifecycle) .launchIn(lifecycleScope) // lifecycle-runtime-ktx diff --git a/corbind-activity/build.gradle.kts b/corbind-activity/build.gradle.kts index 6df63bea..7a8bcb8a 100644 --- a/corbind-activity/build.gradle.kts +++ b/corbind-activity/build.gradle.kts @@ -20,7 +20,11 @@ plugins { id("corbind.dokka") } +android { + namespace = "ru.ldralighieri.corbind.activity" +} + dependencies { - api(project(":corbind")) + api(projects.corbind) api(libs.androidx.activity) } diff --git a/corbind-activity/src/main/AndroidManifest.xml b/corbind-activity/src/main/AndroidManifest.xml index 55303043..37f07226 100644 --- a/corbind-activity/src/main/AndroidManifest.xml +++ b/corbind-activity/src/main/AndroidManifest.xml @@ -14,4 +14,4 @@ ~ limitations under the License. --> - + diff --git a/corbind-activity/src/main/kotlin/ru/ldralighieri/corbind/activity/OnBackPressedDispatcherBackPresses.kt b/corbind-activity/src/main/kotlin/ru/ldralighieri/corbind/activity/OnBackPressedDispatcherBackPresses.kt index a5ce56f9..4b3ad8e1 100644 --- a/corbind-activity/src/main/kotlin/ru/ldralighieri/corbind/activity/OnBackPressedDispatcherBackPresses.kt +++ b/corbind-activity/src/main/kotlin/ru/ldralighieri/corbind/activity/OnBackPressedDispatcherBackPresses.kt @@ -36,14 +36,14 @@ import ru.ldralighieri.corbind.internal.corbindReceiveChannel * Perform an action on [OnBackPressedDispatcher.onBackPressed] call. * * @param scope Root coroutine scope + * @param lifecycleOwner The LifecycleOwner which controls when the callback should be invoked * @param capacity Capacity of the channel's buffer (no buffer by default) - * @param owner The LifecycleOwner which controls when the callback should be invoked * @param action An action to perform */ fun OnBackPressedDispatcher.backPresses( scope: CoroutineScope, + lifecycleOwner: LifecycleOwner, capacity: Int = Channel.RENDEZVOUS, - owner: LifecycleOwner, action: suspend () -> Unit ) { val events = scope.actor(Dispatchers.Main.immediate, capacity) { @@ -51,23 +51,23 @@ fun OnBackPressedDispatcher.backPresses( } val callback = callback(scope, events::trySend) - addCallback(owner, callback) + addCallback(lifecycleOwner, callback) events.invokeOnClose { callback.remove() } } /** * Perform an action on [OnBackPressedDispatcher.onBackPressed] call, inside new [CoroutineScope]. * + * @param lifecycleOwner The LifecycleOwner which controls when the callback should be invoked * @param capacity Capacity of the channel's buffer (no buffer by default) - * @param owner The LifecycleOwner which controls when the callback should be invoked * @param action An action to perform */ suspend fun OnBackPressedDispatcher.backPresses( + lifecycleOwner: LifecycleOwner, capacity: Int = Channel.RENDEZVOUS, - owner: LifecycleOwner, action: suspend () -> Unit ) = coroutineScope { - backPresses(this, capacity, owner, action) + backPresses(this, lifecycleOwner, capacity, action) } /** @@ -77,22 +77,22 @@ suspend fun OnBackPressedDispatcher.backPresses( * * ``` * launch { - * requireActivity().onBackPressedDispatcher.backPresses() + * onBackPressedDispatcher.backPresses(lifecycleOwner = this) * .consumeEach { /* handle onBackPressed event */ } * } * ``` * * @param scope Root coroutine scope + * @param lifecycleOwner The LifecycleOwner which controls when the callback should be invoked * @param capacity Capacity of the channel's buffer (no buffer by default) - * @param owner The LifecycleOwner which controls when the callback should be invoked */ fun OnBackPressedDispatcher.backPresses( scope: CoroutineScope, - capacity: Int = Channel.RENDEZVOUS, - owner: LifecycleOwner + lifecycleOwner: LifecycleOwner, + capacity: Int = Channel.RENDEZVOUS ): ReceiveChannel = corbindReceiveChannel(capacity) { val callback = callback(scope, ::trySend) - addCallback(owner, callback) + addCallback(lifecycleOwner, callback) invokeOnClose { callback.remove() } } @@ -102,17 +102,17 @@ fun OnBackPressedDispatcher.backPresses( * Example: * * ``` - * requireActivity().onBackPressedDispatcher.backPresses() + * onBackPressedDispatcher.backPresses(lifecycleOwner = this) * .onEach { /* handle onBackPressed event */ } * .flowWithLifecycle(lifecycle) * .launchIn(lifecycleScope) // lifecycle-runtime-ktx * ``` * - * @param owner The LifecycleOwner which controls when the callback should be invoked + * @param lifecycleOwner The LifecycleOwner which controls when the callback should be invoked */ -fun OnBackPressedDispatcher.backPresses(owner: LifecycleOwner): Flow = channelFlow { +fun OnBackPressedDispatcher.backPresses(lifecycleOwner: LifecycleOwner): Flow = channelFlow { val callback = callback(this, ::trySend) - addCallback(owner, callback) + addCallback(lifecycleOwner, callback) awaitClose { callback.remove() } } diff --git a/corbind-appcompat/build.gradle.kts b/corbind-appcompat/build.gradle.kts index b34fd2d5..b20cd2d8 100644 --- a/corbind-appcompat/build.gradle.kts +++ b/corbind-appcompat/build.gradle.kts @@ -20,7 +20,11 @@ plugins { id("corbind.dokka") } +android { + namespace = "ru.ldralighieri.corbind.appcompat" +} + dependencies { - api(project(":corbind")) + api(projects.corbind) api(libs.androidx.appcompat) } diff --git a/corbind-appcompat/src/main/AndroidManifest.xml b/corbind-appcompat/src/main/AndroidManifest.xml index b8c28a2e..72c68ac6 100644 --- a/corbind-appcompat/src/main/AndroidManifest.xml +++ b/corbind-appcompat/src/main/AndroidManifest.xml @@ -14,4 +14,4 @@ ~ limitations under the License. --> - + diff --git a/corbind-core/build.gradle.kts b/corbind-core/build.gradle.kts index bd63232d..e7d0289a 100644 --- a/corbind-core/build.gradle.kts +++ b/corbind-core/build.gradle.kts @@ -20,7 +20,11 @@ plugins { id("corbind.dokka") } +android { + namespace = "ru.ldralighieri.corbind.core" +} + dependencies { - api(project(":corbind")) + api(projects.corbind) api(libs.androidx.core) } diff --git a/corbind-core/src/main/AndroidManifest.xml b/corbind-core/src/main/AndroidManifest.xml index 0944727d..72c68ac6 100644 --- a/corbind-core/src/main/AndroidManifest.xml +++ b/corbind-core/src/main/AndroidManifest.xml @@ -14,4 +14,4 @@ ~ limitations under the License. --> - + diff --git a/corbind-drawerlayout/build.gradle.kts b/corbind-drawerlayout/build.gradle.kts index 33d4f277..06e339db 100644 --- a/corbind-drawerlayout/build.gradle.kts +++ b/corbind-drawerlayout/build.gradle.kts @@ -20,7 +20,11 @@ plugins { id("corbind.dokka") } +android { + namespace = "ru.ldralighieri.corbind.drawerlayout" +} + dependencies { - api(project(":corbind")) + api(projects.corbind) api(libs.androidx.drawerlayout) } diff --git a/corbind-drawerlayout/src/main/AndroidManifest.xml b/corbind-drawerlayout/src/main/AndroidManifest.xml index 1625eb16..72c68ac6 100644 --- a/corbind-drawerlayout/src/main/AndroidManifest.xml +++ b/corbind-drawerlayout/src/main/AndroidManifest.xml @@ -14,4 +14,4 @@ ~ limitations under the License. --> - + diff --git a/corbind-leanback/build.gradle.kts b/corbind-leanback/build.gradle.kts index ccd491f2..532482de 100644 --- a/corbind-leanback/build.gradle.kts +++ b/corbind-leanback/build.gradle.kts @@ -20,7 +20,11 @@ plugins { id("corbind.dokka") } +android { + namespace = "ru.ldralighieri.corbind.leanback" +} + dependencies { - api(project(":corbind")) + api(projects.corbind) api(libs.androidx.leanback) } diff --git a/corbind-leanback/src/main/AndroidManifest.xml b/corbind-leanback/src/main/AndroidManifest.xml index 4a822ac9..edf10ff3 100644 --- a/corbind-leanback/src/main/AndroidManifest.xml +++ b/corbind-leanback/src/main/AndroidManifest.xml @@ -14,4 +14,5 @@ ~ limitations under the License. --> - + diff --git a/corbind-lifecycle/build.gradle.kts b/corbind-lifecycle/build.gradle.kts index 1446c2de..0770b5bd 100644 --- a/corbind-lifecycle/build.gradle.kts +++ b/corbind-lifecycle/build.gradle.kts @@ -20,7 +20,11 @@ plugins { id("corbind.dokka") } +android { + namespace = "ru.ldralighieri.corbind.lifecycle" +} + dependencies { - api(project(":corbind")) + api(projects.corbind) api(libs.androidx.lifecycle.runtime.ktx) } diff --git a/corbind-lifecycle/src/main/AndroidManifest.xml b/corbind-lifecycle/src/main/AndroidManifest.xml index 228d677e..37f07226 100644 --- a/corbind-lifecycle/src/main/AndroidManifest.xml +++ b/corbind-lifecycle/src/main/AndroidManifest.xml @@ -14,4 +14,4 @@ ~ limitations under the License. --> - + diff --git a/corbind-material/build.gradle.kts b/corbind-material/build.gradle.kts index e2de6279..56119935 100644 --- a/corbind-material/build.gradle.kts +++ b/corbind-material/build.gradle.kts @@ -20,7 +20,11 @@ plugins { id("corbind.dokka") } +android { + namespace = "ru.ldralighieri.corbind.material" +} + dependencies { - api(project(":corbind")) + api(projects.corbind) api(libs.material) } diff --git a/corbind-material/src/main/AndroidManifest.xml b/corbind-material/src/main/AndroidManifest.xml index 410bb2b4..72c68ac6 100644 --- a/corbind-material/src/main/AndroidManifest.xml +++ b/corbind-material/src/main/AndroidManifest.xml @@ -14,4 +14,4 @@ ~ limitations under the License. --> - + diff --git a/corbind-navigation/build.gradle.kts b/corbind-navigation/build.gradle.kts index 73a9cbe3..373c3aab 100644 --- a/corbind-navigation/build.gradle.kts +++ b/corbind-navigation/build.gradle.kts @@ -20,7 +20,11 @@ plugins { id("corbind.dokka") } +android { + namespace = "ru.ldralighieri.corbind.navigation" +} + dependencies { - api(project(":corbind")) + api(projects.corbind) api(libs.androidx.navigation) } diff --git a/corbind-navigation/src/main/AndroidManifest.xml b/corbind-navigation/src/main/AndroidManifest.xml index c730af9e..72c68ac6 100644 --- a/corbind-navigation/src/main/AndroidManifest.xml +++ b/corbind-navigation/src/main/AndroidManifest.xml @@ -14,4 +14,4 @@ ~ limitations under the License. --> - + diff --git a/corbind-recyclerview/build.gradle.kts b/corbind-recyclerview/build.gradle.kts index c0165633..b083e977 100644 --- a/corbind-recyclerview/build.gradle.kts +++ b/corbind-recyclerview/build.gradle.kts @@ -20,7 +20,11 @@ plugins { id("corbind.dokka") } +android { + namespace = "ru.ldralighieri.corbind.recyclerview" +} + dependencies { - api(project(":corbind")) + api(projects.corbind) api(libs.androidx.recyclerview) } diff --git a/corbind-recyclerview/src/main/AndroidManifest.xml b/corbind-recyclerview/src/main/AndroidManifest.xml index 39a84644..72c68ac6 100644 --- a/corbind-recyclerview/src/main/AndroidManifest.xml +++ b/corbind-recyclerview/src/main/AndroidManifest.xml @@ -14,4 +14,4 @@ ~ limitations under the License. --> - + diff --git a/corbind-slidingpanelayout/build.gradle.kts b/corbind-slidingpanelayout/build.gradle.kts index 7af692a4..37aa91b7 100644 --- a/corbind-slidingpanelayout/build.gradle.kts +++ b/corbind-slidingpanelayout/build.gradle.kts @@ -20,7 +20,11 @@ plugins { id("corbind.dokka") } +android { + namespace = "ru.ldralighieri.corbind.slidingpanelayout" +} + dependencies { - api(project(":corbind")) + api(projects.corbind) api(libs.androidx.slidingpanelayout) } diff --git a/corbind-slidingpanelayout/src/main/AndroidManifest.xml b/corbind-slidingpanelayout/src/main/AndroidManifest.xml index 50c82ee6..72c68ac6 100644 --- a/corbind-slidingpanelayout/src/main/AndroidManifest.xml +++ b/corbind-slidingpanelayout/src/main/AndroidManifest.xml @@ -14,4 +14,4 @@ ~ limitations under the License. --> - + diff --git a/corbind-swiperefreshlayout/build.gradle.kts b/corbind-swiperefreshlayout/build.gradle.kts index c5e34a6e..41ec6e04 100644 --- a/corbind-swiperefreshlayout/build.gradle.kts +++ b/corbind-swiperefreshlayout/build.gradle.kts @@ -20,7 +20,11 @@ plugins { id("corbind.dokka") } +android { + namespace = "ru.ldralighieri.corbind.swiperefreshlayout" +} + dependencies { - api(project(":corbind")) + api(projects.corbind) api(libs.androidx.swiperefreshlayout) } diff --git a/corbind-swiperefreshlayout/src/main/AndroidManifest.xml b/corbind-swiperefreshlayout/src/main/AndroidManifest.xml index 9a859c8b..72c68ac6 100644 --- a/corbind-swiperefreshlayout/src/main/AndroidManifest.xml +++ b/corbind-swiperefreshlayout/src/main/AndroidManifest.xml @@ -14,4 +14,4 @@ ~ limitations under the License. --> - + diff --git a/corbind-viewpager/build.gradle.kts b/corbind-viewpager/build.gradle.kts index 5147e68c..f5530069 100644 --- a/corbind-viewpager/build.gradle.kts +++ b/corbind-viewpager/build.gradle.kts @@ -20,7 +20,11 @@ plugins { id("corbind.dokka") } +android { + namespace = "ru.ldralighieri.corbind.viewpager" +} + dependencies { - api(project(":corbind")) + api(projects.corbind) api(libs.androidx.viewpager) } diff --git a/corbind-viewpager/src/main/AndroidManifest.xml b/corbind-viewpager/src/main/AndroidManifest.xml index 7f1308d0..72c68ac6 100644 --- a/corbind-viewpager/src/main/AndroidManifest.xml +++ b/corbind-viewpager/src/main/AndroidManifest.xml @@ -14,4 +14,4 @@ ~ limitations under the License. --> - + diff --git a/corbind-viewpager2/build.gradle.kts b/corbind-viewpager2/build.gradle.kts index b276a39b..13aeba89 100644 --- a/corbind-viewpager2/build.gradle.kts +++ b/corbind-viewpager2/build.gradle.kts @@ -20,7 +20,11 @@ plugins { id("corbind.dokka") } +android { + namespace = "ru.ldralighieri.corbind.viewpager2" +} + dependencies { - api(project(":corbind")) + api(projects.corbind) api(libs.androidx.viewpager2) } diff --git a/corbind-viewpager2/src/main/AndroidManifest.xml b/corbind-viewpager2/src/main/AndroidManifest.xml index a2f890e2..72c68ac6 100644 --- a/corbind-viewpager2/src/main/AndroidManifest.xml +++ b/corbind-viewpager2/src/main/AndroidManifest.xml @@ -14,4 +14,4 @@ ~ limitations under the License. --> - + diff --git a/corbind/build.gradle.kts b/corbind/build.gradle.kts index ab0d1042..bb097f0c 100644 --- a/corbind/build.gradle.kts +++ b/corbind/build.gradle.kts @@ -20,6 +20,10 @@ plugins { id("corbind.dokka") } +android { + namespace = "ru.ldralighieri.corbind" +} + dependencies { api(libs.kotlin.stdlib) api(libs.kotlin.coroutines.android) diff --git a/corbind/src/main/AndroidManifest.xml b/corbind/src/main/AndroidManifest.xml index cae538bd..41ccfa5d 100644 --- a/corbind/src/main/AndroidManifest.xml +++ b/corbind/src/main/AndroidManifest.xml @@ -14,5 +14,5 @@ ~ limitations under the License. --> - + diff --git a/gradle.properties b/gradle.properties index 7d2c57cd..02df4001 100644 --- a/gradle.properties +++ b/gradle.properties @@ -4,9 +4,9 @@ org.gradle.jvmargs=-XX:MaxMetaspaceSize=3G # AndroidX android.useAndroidX=true -android.compileSdk=32 -android.targetSdk=32 -android.minSdk=14 +compileSdk=33 +targetSdk=33 +minSdk=14 # Maven diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 00e83ede..329ca624 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -1,31 +1,32 @@ [versions] spotless = "6.8.0" -gver = "0.42.0" +gver = "0.43.0" detekt = "1.21.0" -dokka = "1.6.10" -maven-publish = "0.21.0" +dokka = "1.7.20" +maven-publish = "0.22.0" -plugin-android = "7.2.1" +plugin-android = "7.3.1" -kotlin = "1.7.10" +kotlin = "1.7.20" kotlin-coroutines = "1.6.4" -androidx-core = "1.8.0" -androidx-annotation = "1.4.0" -androidx-appcompat = "1.4.2" +androidx-core = "1.9.0" +androidx-annotation = "1.5.0" +androidx-appcompat = "1.5.1" androidx-drawerlayout = "1.1.1" androidx-leanback = "1.0.0" -androidx-navigation = "2.5.0" +androidx-navigation = "2.5.2" androidx-recyclerview = "1.2.1" androidx-slidingpanelayout = "1.2.0" androidx-swiperefreshlayout = "1.1.0" androidx-viewpager = "1.0.0" androidx-viewpager2 = "1.0.0" -androidx-lifecycle = "2.5.0" -androidx-activity = "1.5.0" +androidx-lifecycle = "2.5.1" +androidx-activity = "1.6.0" +androidx-fragment = "1.5.3" androidx-constraintlayout = "2.1.4" -material = "1.6.1" +material = "1.7.0" ktlint = "0.46.1" @@ -60,6 +61,7 @@ androidx-viewpager = { module = "androidx.viewpager:viewpager", version.ref = "a androidx-viewpager2 = { module = "androidx.viewpager2:viewpager2", version.ref = "androidx-viewpager2" } androidx-lifecycle-runtime-ktx = { module = "androidx.lifecycle:lifecycle-runtime-ktx", version.ref = "androidx-lifecycle" } androidx-activity = { module = "androidx.activity:activity", version.ref = "androidx-activity" } +androidx-fragment = { module = "androidx.fragment:fragment", version.ref = "androidx-fragment" } androidx-constraintlayout = { module = "androidx.constraintlayout:constraintlayout", version.ref = "androidx-constraintlayout" } material = { module = "com.google.android.material:material", version.ref = "material" } diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 97735d5c..cbff8992 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -18,4 +18,4 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-7.5-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-7.5.1-all.zip diff --git a/sample/build.gradle.kts b/sample/build.gradle.kts index cbaed1c5..44032297 100644 --- a/sample/build.gradle.kts +++ b/sample/build.gradle.kts @@ -20,13 +20,20 @@ plugins { } android { - compileSdk = findProperty("android.compileSdk").toString().toInt() + val compileSdk: String by project + val minSdk: String by project + val targetSdk: String by project + @Suppress("LocalVariableName") val VERSION_NAME: String by project + + namespace = "ru.ldralighieri.corbind.sample" + + this.compileSdk = compileSdk.toInt() defaultConfig { applicationId = "ru.ldralighieri.corbind.example" - minSdk = findProperty("android.minSdk").toString().toInt() - targetSdk = findProperty("android.targetSdk").toString().toInt() + this.minSdk = minSdk.toInt() + this.targetSdk = targetSdk.toInt() versionCode = 1 - versionName = findProperty("VERSION_NAME").toString() + versionName = VERSION_NAME vectorDrawables.useSupportLibrary = true } @@ -68,7 +75,7 @@ android { } dependencies { - implementation(project(":corbind-swiperefreshlayout")) + implementation(projects.corbindSwiperefreshlayout) implementation(libs.androidx.appcompat) implementation(libs.androidx.lifecycle.runtime.ktx) diff --git a/sample/src/main/AndroidManifest.xml b/sample/src/main/AndroidManifest.xml index b0efd672..5f292616 100644 --- a/sample/src/main/AndroidManifest.xml +++ b/sample/src/main/AndroidManifest.xml @@ -15,18 +15,15 @@ --> + xmlns:tools="http://schemas.android.com/tools"> + tools:ignore="GoogleAppIndexingWarning"> Date: Thu, 20 Oct 2022 00:43:59 +0300 Subject: [PATCH 2/3] added corbind-fragment module and FragmentManager resultEvents extension --- README.md | 1 + build.gradle.kts | 1 + corbind-fragment/.gitignore | 1 + corbind-fragment/README.md | 30 ++++ corbind-fragment/build.gradle.kts | 30 ++++ corbind-fragment/gradle.properties | 20 +++ corbind-fragment/proguard-rules.pro | 21 +++ corbind-fragment/src/main/AndroidManifest.xml | 17 ++ .../fragment/FragmentManagerResultEvents.kt | 161 ++++++++++++++++++ corbind-material/README.md | 5 +- settings.gradle.kts | 1 + 11 files changed, 284 insertions(+), 4 deletions(-) create mode 100644 corbind-fragment/.gitignore create mode 100644 corbind-fragment/README.md create mode 100644 corbind-fragment/build.gradle.kts create mode 100644 corbind-fragment/gradle.properties create mode 100644 corbind-fragment/proguard-rules.pro create mode 100644 corbind-fragment/src/main/AndroidManifest.xml create mode 100644 corbind-fragment/src/main/kotlin/ru/ldralighieri/corbind/fragment/FragmentManagerResultEvents.kt diff --git a/README.md b/README.md index 11006fa8..9ba9fb28 100644 --- a/README.md +++ b/README.md @@ -34,6 +34,7 @@ implementation 'ru.ldralighieri.corbind:corbind-activity:1.5.5' implementation 'ru.ldralighieri.corbind:corbind-appcompat:1.5.5' implementation 'ru.ldralighieri.corbind:corbind-core:1.5.5' implementation 'ru.ldralighieri.corbind:corbind-drawerlayout:1.5.5' +implementation 'ru.ldralighieri.corbind:corbind-fragment:1.5.5' implementation 'ru.ldralighieri.corbind:corbind-leanback:1.5.5' implementation 'ru.ldralighieri.corbind:corbind-lifecycle:1.5.5' implementation 'ru.ldralighieri.corbind:corbind-navigation:1.5.5' diff --git a/build.gradle.kts b/build.gradle.kts index 40c473e2..8f8794b7 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -40,6 +40,7 @@ detekt { "corbind-appcompat/src/main/kotlin", "corbind-core/src/main/kotlin", "corbind-drawerlayout/src/main/kotlin", + "corbind-fragment/src/main/kotlin", "corbind-leanback/src/main/kotlin", "corbind-lifecycle/src/main/kotlin", "corbind-material/src/main/kotlin", diff --git a/corbind-fragment/.gitignore b/corbind-fragment/.gitignore new file mode 100644 index 00000000..42afabfd --- /dev/null +++ b/corbind-fragment/.gitignore @@ -0,0 +1 @@ +/build \ No newline at end of file diff --git a/corbind-fragment/README.md b/corbind-fragment/README.md new file mode 100644 index 00000000..e5615339 --- /dev/null +++ b/corbind-fragment/README.md @@ -0,0 +1,30 @@ + +# corbind-activity + +To add androidx fragment bindings, import `corbind-fragment` module: + +```groovy +implementation 'ru.ldralighieri.corbind:corbind-fragment:1.6.0' +``` + +## List of extensions + +Component | Extension | Description +--|---|-- +**FragmentManager** | `resultEvents` | Called when any results set by setFragmentResult using the same requestKey. + + +## Simple examples + +```kotlin +lifecycleScope.launchWhenStarted { + parentFragmentManager.resultEvents( + requestKey = FRAGMENT_REQUEST_KEY, + lifecycleOwner = this@CurrentFragment + ) + .onEach { event -> /* handle result event */ } + .launchIn(this@launchWhenStarted) // lifecycle-runtime-ktx +} +``` + +More examples in source code diff --git a/corbind-fragment/build.gradle.kts b/corbind-fragment/build.gradle.kts new file mode 100644 index 00000000..7a7abca8 --- /dev/null +++ b/corbind-fragment/build.gradle.kts @@ -0,0 +1,30 @@ +/* + * Copyright 2022 Vladimir Raupov + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +plugins { + id("corbind.library") + id("corbind.spotless") + id("corbind.dokka") +} + +android { + namespace = "ru.ldralighieri.corbind.fragment" +} + +dependencies { + api(projects.corbind) + api(libs.androidx.fragment) +} diff --git a/corbind-fragment/gradle.properties b/corbind-fragment/gradle.properties new file mode 100644 index 00000000..6421b44e --- /dev/null +++ b/corbind-fragment/gradle.properties @@ -0,0 +1,20 @@ +# +# Copyright 2022 Vladimir Raupov +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + + +POM_ARTIFACT_ID=corbind-fragment +POM_NAME=Corbind (fragment) +POM_PACKAGING=aar diff --git a/corbind-fragment/proguard-rules.pro b/corbind-fragment/proguard-rules.pro new file mode 100644 index 00000000..ff59496d --- /dev/null +++ b/corbind-fragment/proguard-rules.pro @@ -0,0 +1,21 @@ +# Add project specific ProGuard rules here. +# You can control the set of applied configuration files using the +# proguardFiles setting in build.gradle.kts. +# +# For more details, see +# http://developer.android.com/guide/developing/tools/proguard.html + +# If your project uses WebView with JS, uncomment the following +# and specify the fully qualified class name to the JavaScript interface +# class: +#-keepclassmembers class fqcn.of.javascript.interface.for.webview { +# public *; +#} + +# Uncomment this to preserve the line number information for +# debugging stack traces. +#-keepattributes SourceFile,LineNumberTable + +# If you keep the line number information, uncomment this to +# hide the original source file name. +#-renamesourcefileattribute SourceFile \ No newline at end of file diff --git a/corbind-fragment/src/main/AndroidManifest.xml b/corbind-fragment/src/main/AndroidManifest.xml new file mode 100644 index 00000000..e5980f6b --- /dev/null +++ b/corbind-fragment/src/main/AndroidManifest.xml @@ -0,0 +1,17 @@ + + + diff --git a/corbind-fragment/src/main/kotlin/ru/ldralighieri/corbind/fragment/FragmentManagerResultEvents.kt b/corbind-fragment/src/main/kotlin/ru/ldralighieri/corbind/fragment/FragmentManagerResultEvents.kt new file mode 100644 index 00000000..59d89c35 --- /dev/null +++ b/corbind-fragment/src/main/kotlin/ru/ldralighieri/corbind/fragment/FragmentManagerResultEvents.kt @@ -0,0 +1,161 @@ +/* + * Copyright 2022 Vladimir Raupov + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package ru.ldralighieri.corbind.fragment + +import android.os.Bundle +import androidx.annotation.CheckResult +import androidx.fragment.app.FragmentManager +import androidx.lifecycle.LifecycleOwner +import kotlinx.coroutines.CoroutineScope +import kotlinx.coroutines.Dispatchers +import kotlinx.coroutines.channels.Channel +import kotlinx.coroutines.channels.ReceiveChannel +import kotlinx.coroutines.channels.actor +import kotlinx.coroutines.channels.awaitClose +import kotlinx.coroutines.coroutineScope +import kotlinx.coroutines.flow.Flow +import kotlinx.coroutines.flow.channelFlow +import kotlinx.coroutines.isActive +import ru.ldralighieri.corbind.internal.corbindReceiveChannel + +data class FragmentResultEvent( + val requestKey: String, + val bundle: Bundle +) + +/** + * Perform an action on any results set by setFragmentResult using the [requestKey], once the given + * [lifecycleOwner][LifecycleOwner] is at least in the STARTED state + * + * *Warning:* The created actor uses [FragmentManager.setFragmentResultListener]. Only one flow can + * be used at a time + * + * @param scope Root coroutine scope + * @param requestKey Used to identify the result + * @param lifecycleOwner The LifecycleOwner for handling the result + * @param capacity Capacity of the channel's buffer (no buffer by default) + * @param action An action to perform + */ +fun FragmentManager.resultEvents( + scope: CoroutineScope, + requestKey: String, + lifecycleOwner: LifecycleOwner, + capacity: Int = Channel.RENDEZVOUS, + action: suspend (FragmentResultEvent) -> Unit +) { + val events = scope.actor(Dispatchers.Main.immediate, capacity) { + for (event in channel) action(event) + } + + val listener = listener(scope, events::trySend) + setFragmentResultListener(requestKey, lifecycleOwner, listener) + events.invokeOnClose { clearFragmentResultListener(requestKey) } +} + +/** + * Perform an action inside new [CoroutineScope] on any results set by setFragmentResult using the + * [requestKey], once the given [lifecycleOwner][LifecycleOwner] is at least in the STARTED state + * + * *Warning:* The created actor uses [FragmentManager.setFragmentResultListener]. Only one flow can + * be used at a time + * + * @param requestKey Used to identify the result + * @param lifecycleOwner The LifecycleOwner for handling the result + * @param capacity Capacity of the channel's buffer (no buffer by default) + * @param action An action to perform + */ +suspend fun FragmentManager.resultEvents( + requestKey: String, + lifecycleOwner: LifecycleOwner, + capacity: Int = Channel.RENDEZVOUS, + action: suspend (FragmentResultEvent) -> Unit +) = coroutineScope { + resultEvents(this, requestKey, lifecycleOwner, capacity, action) +} + +/** + * Create a channel which emits any results set by setFragmentResult using the [requestKey], once + * the given [lifecycleOwner][LifecycleOwner] is at least in the STARTED state + * + * *Warning:* The created channel uses [FragmentManager.setFragmentResultListener]. Only one flow + * can be used at a time + * + * Example: + * + * ``` + * launch { + * parentFragmentManager.resultEvents( + * requestKey = FRAGMENT_REQUEST_KEY, + * lifecycleOwner = this@CurrentFragment + * ) + * .consumeEach { /* handle result event */ } + * } + * ``` + * + * @param scope Root coroutine scope + * @param requestKey Used to identify the result + * @param lifecycleOwner The LifecycleOwner for handling the result + */ +fun FragmentManager.resultEvents( + scope: CoroutineScope, + requestKey: String, + lifecycleOwner: LifecycleOwner, + capacity: Int = Channel.RENDEZVOUS +): ReceiveChannel = corbindReceiveChannel(capacity) { + val listener = listener(scope, ::trySend) + setFragmentResultListener(requestKey, lifecycleOwner, listener) + invokeOnClose { clearFragmentResultListener(requestKey) } +} + +/** + * Create a flow which emits any results set by setFragmentResult using the [requestKey], once the + * given [lifecycleOwner][LifecycleOwner] is at least in the STARTED state + * + * *Warning:* The created flow uses [FragmentManager.setFragmentResultListener]. Only one flow can + * be used at a time + * + * Example: + * ``` + * lifecycleScope.launchWhenStarted { + * parentFragmentManager.resultEvents( + * requestKey = FRAGMENT_REQUEST_KEY, + * lifecycleOwner = this@CurrentFragment + * ) + * .onEach { event -> /* handle result event */ } + * .launchIn(this@launchWhenStarted) // lifecycle-runtime-ktx + * } + * ``` + * + * @param requestKey Used to identify the result + * @param lifecycleOwner The LifecycleOwner for handling the result + */ +fun FragmentManager.resultEvents( + requestKey: String, + lifecycleOwner: LifecycleOwner +): Flow = channelFlow { + val listener = listener(this, ::trySend) + setFragmentResultListener(requestKey, lifecycleOwner, listener) + awaitClose { clearFragmentResultListener(requestKey) } +} + +@CheckResult +private fun listener( + scope: CoroutineScope, + emitter: (FragmentResultEvent) -> Unit +) = { requestKey: String, bundle: Bundle -> + if (scope.isActive) { emitter(FragmentResultEvent(requestKey, bundle)) } +} diff --git a/corbind-material/README.md b/corbind-material/README.md index a0cf7d4a..d1e64abc 100644 --- a/corbind-material/README.md +++ b/corbind-material/README.md @@ -54,10 +54,7 @@ Component | Extension | Description ```kotlin chipGroup.checkedChanges() // Flow - .onEach { - tv_message = - if (it != View.NO_ID) "Chip #$it selected" else "No one сhip selected" - } + .onEach { /* handle checked ids */ } .flowWithLifecycle(lifecycle) .launchIn(lifecycleScope) // lifecycle-runtime-ktx ``` diff --git a/settings.gradle.kts b/settings.gradle.kts index 1dc48224..68a93f1f 100644 --- a/settings.gradle.kts +++ b/settings.gradle.kts @@ -41,6 +41,7 @@ include(":corbind-activity") include(":corbind-appcompat") include(":corbind-core") include(":corbind-drawerlayout") +include(":corbind-fragment") include(":corbind-leanback") include(":corbind-lifecycle") include(":corbind-material") From 4bfa78cba59256996d6ea424af9346708d955b5f Mon Sep 17 00:00:00 2001 From: Vladimir Raupov Date: Thu, 20 Oct 2022 20:11:48 +0300 Subject: [PATCH 3/3] Updated version, README.md of each module and CHANGELOG.md for version 1.6.0 --- CHANGELOG.md | 13 +++++++++++ README.md | 34 ++++++++++++++-------------- corbind-activity/README.md | 2 +- corbind-appcompat/README.md | 2 +- corbind-core/README.md | 2 +- corbind-drawerlayout/README.md | 2 +- corbind-leanback/README.md | 2 +- corbind-lifecycle/README.md | 2 +- corbind-material/README.md | 2 +- corbind-navigation/README.md | 2 +- corbind-recyclerview/README.md | 2 +- corbind-slidingpanelayout/README.md | 2 +- corbind-swiperefreshlayout/README.md | 2 +- corbind-viewpager/README.md | 2 +- corbind-viewpager2/README.md | 2 +- corbind/README.md | 2 +- gradle.properties | 2 +- 17 files changed, 45 insertions(+), 32 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 99c42b23..480991b7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,19 @@ # ChangeLog +## Version 1.6.0 + +* New: Fragment module +* New: Bindings list: + * AndroidX library bindings: + * `corbind-fragment`: + * `FragmentManager`: + * `resultEvents` +* Update: Kotlin modules dependency to v1.7.20. +* Update: Material components dependency to v1.7.0. +* Update: Minor update of other libraries. + + ## Version 1.5.5 * New: Build logic module. diff --git a/README.md b/README.md index 9ba9fb28..809cd0a1 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ [![Corbind](logo.svg)](https://ldralighieri.github.io/Corbind) [![Maven Central](https://img.shields.io/maven-central/v/ru.ldralighieri.corbind/corbind.svg)](https://search.maven.org/search?q=g:ru.ldralighieri.corbind) -[![Kotlin Version](https://img.shields.io/badge/Kotlin-v1.7.10-blue.svg)](https://kotlinlang.org) +[![Kotlin Version](https://img.shields.io/badge/Kotlin-v1.7.20-blue.svg)](https://kotlinlang.org) [![Kotlin Coroutines Version](https://img.shields.io/badge/Coroutines-v1.6.4-blue.svg)](https://kotlinlang.org/docs/reference/coroutines-overview.html) [![GitHub license](https://img.shields.io/badge/license-Apache%20License%202.0-blue.svg?style=flat)](https://www.apache.org/licenses/LICENSE-2.0) @@ -25,29 +25,29 @@ This library is for Android applications only. Help you to transform Android UI Platform bindings: ```groovy -implementation 'ru.ldralighieri.corbind:corbind:1.5.5' +implementation 'ru.ldralighieri.corbind:corbind:1.6.0' ``` AndroidX library bindings: ```groovy -implementation 'ru.ldralighieri.corbind:corbind-activity:1.5.5' -implementation 'ru.ldralighieri.corbind:corbind-appcompat:1.5.5' -implementation 'ru.ldralighieri.corbind:corbind-core:1.5.5' -implementation 'ru.ldralighieri.corbind:corbind-drawerlayout:1.5.5' -implementation 'ru.ldralighieri.corbind:corbind-fragment:1.5.5' -implementation 'ru.ldralighieri.corbind:corbind-leanback:1.5.5' -implementation 'ru.ldralighieri.corbind:corbind-lifecycle:1.5.5' -implementation 'ru.ldralighieri.corbind:corbind-navigation:1.5.5' -implementation 'ru.ldralighieri.corbind:corbind-recyclerview:1.5.5' -implementation 'ru.ldralighieri.corbind:corbind-slidingpanelayout:1.5.5' -implementation 'ru.ldralighieri.corbind:corbind-swiperefreshlayout:1.5.5' -implementation 'ru.ldralighieri.corbind:corbind-viewpager:1.5.5' -implementation 'ru.ldralighieri.corbind:corbind-viewpager2:1.5.5' +implementation 'ru.ldralighieri.corbind:corbind-activity:1.6.0' +implementation 'ru.ldralighieri.corbind:corbind-appcompat:1.6.0' +implementation 'ru.ldralighieri.corbind:corbind-core:1.6.0' +implementation 'ru.ldralighieri.corbind:corbind-drawerlayout:1.6.0' +implementation 'ru.ldralighieri.corbind:corbind-fragment:1.6.0' +implementation 'ru.ldralighieri.corbind:corbind-leanback:1.6.0' +implementation 'ru.ldralighieri.corbind:corbind-lifecycle:1.6.0' +implementation 'ru.ldralighieri.corbind:corbind-navigation:1.6.0' +implementation 'ru.ldralighieri.corbind:corbind-recyclerview:1.6.0' +implementation 'ru.ldralighieri.corbind:corbind-slidingpanelayout:1.6.0' +implementation 'ru.ldralighieri.corbind:corbind-swiperefreshlayout:1.6.0' +implementation 'ru.ldralighieri.corbind:corbind-viewpager:1.6.0' +implementation 'ru.ldralighieri.corbind:corbind-viewpager2:1.6.0' ``` Google 'material' library bindings: ```groovy -implementation 'ru.ldralighieri.corbind:corbind-material:1.5.5' +implementation 'ru.ldralighieri.corbind:corbind-material:1.6.0' ``` Snapshot build: @@ -57,7 +57,7 @@ repositories { } dependencies { - implementation 'ru.ldralighieri.corbind:{module}:1.5.6-SNAPSHOT' + implementation 'ru.ldralighieri.corbind:{module}:1.6.1-SNAPSHOT' } ``` diff --git a/corbind-activity/README.md b/corbind-activity/README.md index ee06a608..13ff9f28 100644 --- a/corbind-activity/README.md +++ b/corbind-activity/README.md @@ -4,7 +4,7 @@ To add androidx activity bindings, import `corbind-activity` module: ```groovy -implementation 'ru.ldralighieri.corbind:corbind-activity:1.5.5' +implementation 'ru.ldralighieri.corbind:corbind-activity:1.6.0' ``` ## List of extensions diff --git a/corbind-appcompat/README.md b/corbind-appcompat/README.md index acb9a655..b0ac9c6d 100644 --- a/corbind-appcompat/README.md +++ b/corbind-appcompat/README.md @@ -4,7 +4,7 @@ To add androidx appcompat bindings, import `corbind-appcompat` module: ```groovy -implementation 'ru.ldralighieri.corbind:corbind-appcompat:1.5.5' +implementation 'ru.ldralighieri.corbind:corbind-appcompat:1.6.0' ``` ## List of extensions diff --git a/corbind-core/README.md b/corbind-core/README.md index 2e144976..adf4ec6a 100644 --- a/corbind-core/README.md +++ b/corbind-core/README.md @@ -4,7 +4,7 @@ To add androidx core bindings, import `corbind-core` module: ```groovy -implementation 'ru.ldralighieri.corbind:corbind-core:1.5.5' +implementation 'ru.ldralighieri.corbind:corbind-core:1.6.0' ``` ## List of extensions diff --git a/corbind-drawerlayout/README.md b/corbind-drawerlayout/README.md index 9320396d..349a25e6 100644 --- a/corbind-drawerlayout/README.md +++ b/corbind-drawerlayout/README.md @@ -4,7 +4,7 @@ To add androidx drawerlayout bindings, import `corbind-drawerlayout` module: ```groovy -implementation 'ru.ldralighieri.corbind:corbind-drawerlayout:1.5.5' +implementation 'ru.ldralighieri.corbind:corbind-drawerlayout:1.6.0' ``` ## List of extensions diff --git a/corbind-leanback/README.md b/corbind-leanback/README.md index fbff9f14..b82a5723 100644 --- a/corbind-leanback/README.md +++ b/corbind-leanback/README.md @@ -4,7 +4,7 @@ To add androidx leanback bindings, import `corbind-leanback` module: ```groovy -implementation 'ru.ldralighieri.corbind:corbind-leanback:1.5.5' +implementation 'ru.ldralighieri.corbind:corbind-leanback:1.6.0' ``` ## List of extensions diff --git a/corbind-lifecycle/README.md b/corbind-lifecycle/README.md index 1476b5a0..dc226fde 100644 --- a/corbind-lifecycle/README.md +++ b/corbind-lifecycle/README.md @@ -4,7 +4,7 @@ To add androidx lifecycle bindings, import `corbind-lifecycle` module: ```groovy -implementation 'ru.ldralighieri.corbind:corbind-lifecycle:1.5.5' +implementation 'ru.ldralighieri.corbind:corbind-lifecycle:1.6.0' ``` ## List of extensions diff --git a/corbind-material/README.md b/corbind-material/README.md index d1e64abc..354dda15 100644 --- a/corbind-material/README.md +++ b/corbind-material/README.md @@ -4,7 +4,7 @@ To add material bindings, import `corbind-material` module: ```groovy -implementation 'ru.ldralighieri.corbind:corbind-material:1.5.5' +implementation 'ru.ldralighieri.corbind:corbind-material:1.6.0' ``` ## List of extensions diff --git a/corbind-navigation/README.md b/corbind-navigation/README.md index 2b8f7e6e..667cb151 100644 --- a/corbind-navigation/README.md +++ b/corbind-navigation/README.md @@ -4,7 +4,7 @@ To add androidx navigation bindings, import `corbind-navigation` module: ```groovy -implementation 'ru.ldralighieri.corbind:corbind-navigation:1.5.5' +implementation 'ru.ldralighieri.corbind:corbind-navigation:1.6.0' ``` ## List of extensions diff --git a/corbind-recyclerview/README.md b/corbind-recyclerview/README.md index 13480869..f591e400 100644 --- a/corbind-recyclerview/README.md +++ b/corbind-recyclerview/README.md @@ -4,7 +4,7 @@ To add androidx recyclerview bindings, import `corbind-recyclerview` module: ```groovy -implementation 'ru.ldralighieri.corbind:corbind-recyclerview:1.5.5' +implementation 'ru.ldralighieri.corbind:corbind-recyclerview:1.6.0' ``` ## List of extensions diff --git a/corbind-slidingpanelayout/README.md b/corbind-slidingpanelayout/README.md index cb6d76cd..3834fee5 100644 --- a/corbind-slidingpanelayout/README.md +++ b/corbind-slidingpanelayout/README.md @@ -4,7 +4,7 @@ To add androidx slidingpanelayout bindings, import `corbind-slidingpanelayout` module: ```groovy -implementation 'ru.ldralighieri.corbind:corbind-slidingpanelayout:1.5.5' +implementation 'ru.ldralighieri.corbind:corbind-slidingpanelayout:1.6.0' ``` ## List of extensions diff --git a/corbind-swiperefreshlayout/README.md b/corbind-swiperefreshlayout/README.md index 69abfcc0..e3e51a87 100644 --- a/corbind-swiperefreshlayout/README.md +++ b/corbind-swiperefreshlayout/README.md @@ -4,7 +4,7 @@ To add androidx swiperefreshlayout bindings, import `corbind-swiperefreshlayout` module: ```groovy -implementation 'ru.ldralighieri.corbind:corbind-swiperefreshlayout:1.5.5' +implementation 'ru.ldralighieri.corbind:corbind-swiperefreshlayout:1.6.0' ``` ## List of extensions diff --git a/corbind-viewpager/README.md b/corbind-viewpager/README.md index dcf07b5f..26c38e9e 100644 --- a/corbind-viewpager/README.md +++ b/corbind-viewpager/README.md @@ -4,7 +4,7 @@ To add androidx viewpager bindings, import `corbind-viewpager` module: ```groovy -implementation 'ru.ldralighieri.corbind:corbind-viewpager:1.5.5' +implementation 'ru.ldralighieri.corbind:corbind-viewpager:1.6.0' ``` ## List of extensions diff --git a/corbind-viewpager2/README.md b/corbind-viewpager2/README.md index cd715dd5..dd391817 100644 --- a/corbind-viewpager2/README.md +++ b/corbind-viewpager2/README.md @@ -4,7 +4,7 @@ To add androidx viewpager2 bindings, import `corbind-viewpager2` module: ```groovy -implementation 'ru.ldralighieri.corbind:corbind-viewpager2:1.5.5' +implementation 'ru.ldralighieri.corbind:corbind-viewpager2:1.6.0' ``` ## List of extensions diff --git a/corbind/README.md b/corbind/README.md index f81574d8..4ac57e11 100644 --- a/corbind/README.md +++ b/corbind/README.md @@ -4,7 +4,7 @@ To add platform bindings, import `corbind` module: ```groovy -implementation 'ru.ldralighieri.corbind:corbind:1.5.5' +implementation 'ru.ldralighieri.corbind:corbind:1.6.0' ``` ## List of extensions diff --git a/gradle.properties b/gradle.properties index 02df4001..a158455f 100644 --- a/gradle.properties +++ b/gradle.properties @@ -14,7 +14,7 @@ SONATYPE_HOST=DEFAULT RELEASE_SIGNING_ENABLED=true GROUP=ru.ldralighieri.corbind -VERSION_NAME=1.5.6-SNAPSHOT +VERSION_NAME=1.6.0 POM_DESCRIPTION=Kotlin Coroutines binding APIs for Android UI widgets from the platform and support libraries.