Skip to content

Commit 48f647d

Browse files
authored
Kotlin 1.7.20 (#92)
* Kotlin 1.7.20 * Compose 1.3 * Poko 0.11.0 * Add exported=true to AndroidManifests * Compose runtime 1.3.1 * Accompanist 0.27.1 * Binary compatibility validator 0.12.1
1 parent e4a150c commit 48f647d

6 files changed

Lines changed: 35 additions & 27 deletions

File tree

.idea/inspectionProfiles/Project_Default.xml

Lines changed: 5 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

deferred-resources-compose-adapter/build.gradle

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,15 +50,14 @@ android {
5050
}
5151
kotlinOptions {
5252
jvmTarget = JavaVersion.VERSION_1_8
53-
useIR = true
5453
freeCompilerArgs += ["-Xexplicit-api=strict", "-Xopt-in=kotlin.RequiresOptIn"]
5554
}
5655

5756
buildFeatures {
5857
compose true
5958
}
6059
composeOptions {
61-
kotlinCompilerExtensionVersion libs.versions.androidx.compose.get()
60+
kotlinCompilerExtensionVersion libs.versions.androidx.compose.compiler.get()
6261
}
6362

6463
packagingOptions {

demo-compose/build.gradle

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ android {
5555
}
5656

5757
composeOptions {
58-
kotlinCompilerExtensionVersion libs.versions.androidx.compose.get()
58+
kotlinCompilerExtensionVersion libs.versions.androidx.compose.compiler.get()
5959
}
6060
}
6161

@@ -69,10 +69,10 @@ dependencies {
6969
implementation(libs.androidx.compose.ui)
7070
implementation(libs.androidx.compose.uiTooling)
7171

72-
implementation("androidx.activity:activity-compose:1.3.1")
73-
implementation("androidx.compose.material:material:${libs.versions.androidx.compose.get()}")
74-
implementation("androidx.lifecycle:lifecycle-viewmodel-compose:1.0.0-alpha07")
72+
implementation("androidx.activity:activity-compose:1.4.0")
73+
implementation("androidx.compose.material:material:${libs.versions.androidx.compose.runtime.get()}")
74+
implementation("androidx.lifecycle:lifecycle-viewmodel-compose:2.4.0")
7575
implementation("com.google.accompanist:accompanist-pager:${libs.versions.accompanist.get()}")
76-
implementation("com.google.android.material:compose-theme-adapter:${libs.versions.androidx.compose.get()}")
76+
implementation("com.google.android.material:compose-theme-adapter:1.1.1")
7777

7878
}

demo-compose/src/main/java/com/backbase/deferredresources/demo/compose/ComposeDemoActivity.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,7 @@ class ComposeDemoActivity : ComponentActivity() {
117117
}
118118

119119
HorizontalPager(
120+
count = 4,
120121
state = pagerState,
121122
) { page ->
122123
when (page) {
@@ -140,7 +141,7 @@ class ComposeDemoActivity : ComponentActivity() {
140141
selected = index == pagerState.currentPage,
141142
onClick = {
142143
coroutineScope.launch {
143-
pagerState.animateScrollToPage(index, skipPages = false)
144+
pagerState.animateScrollToPage(page = index)
144145
}
145146
},
146147
text = {
@@ -150,7 +151,6 @@ class ComposeDemoActivity : ComponentActivity() {
150151

151152
private fun mutablePagerState(currentPage: Int = 0) = mutableStateOf(
152153
PagerState(
153-
pageCount = 4,
154154
currentPage = currentPage,
155155
)
156156
)

demo/src/main/AndroidManifest.xml

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,8 @@
1414
~ limitations under the License.
1515
-->
1616

17-
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
17+
<manifest
18+
xmlns:android="http://schemas.android.com/apk/res/android"
1819
package="com.backbase.deferredresources.demo">
1920

2021
<application
@@ -25,11 +26,13 @@
2526
android:supportsRtl="true"
2627
android:theme="@style/Theme.DeferredResourcesDemo">
2728

28-
<activity android:name=".DemoActivity">
29-
<intent-filter>
30-
<action android:name="android.intent.action.MAIN" />
31-
<category android:name="android.intent.category.LAUNCHER" />
32-
</intent-filter>
29+
<activity
30+
android:name=".DemoActivity"
31+
android:exported="true">
32+
<intent-filter>
33+
<action android:name="android.intent.action.MAIN" />
34+
<category android:name="android.intent.category.LAUNCHER" />
35+
</intent-filter>
3336
</activity>
3437

3538
</application>

gradle/libs.versions.toml

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,23 @@
11
[versions]
2-
accompanist = "0.16.0"
3-
androidx-compose = "1.0.1"
2+
accompanist = "0.27.1"
3+
androidx-compose-compiler = "1.3.2"
4+
androidx-compose-runtime = "1.3.1"
45
android-test = "1.3.0"
5-
kotlin = "1.5.21"
6-
poko = "0.8.1"
6+
kotlin = "1.7.20"
7+
poko = "0.11.0"
78

89
[libraries]
910
accompanist-drawablePainter = { module = "com.google.accompanist:accompanist-drawablepainter", version.ref = "accompanist" }
1011
android-gradlePlugin = { module = "com.android.tools.build:gradle", version = "7.3.1" }
1112
androidx-annotations = { module = "androidx.annotation:annotation", version = "1.1.0" }
1213
androidx-appCompat = { module = "androidx.appcompat:appcompat", version = "1.3.0" }
13-
androidx-compose-foundation = { module = "androidx.compose.foundation:foundation", version.ref = "androidx-compose" }
14-
androidx-compose-material = { module = "androidx.compose.material:material", version.ref = "androidx-compose" }
15-
androidx-compose-materialIcons = { module = "androidx.compose.material:material-icons-extended", version.ref = "androidx-compose" }
16-
androidx-compose-runtime = { module = "androidx.compose.runtime:runtime", version.ref = "androidx-compose" }
17-
androidx-compose-ui = { module = "androidx.compose.ui:ui", version.ref = "androidx-compose" }
18-
androidx-compose-uiTest = { module = "androidx.compose.ui:ui-test-junit4", version.ref = "androidx-compose" }
19-
androidx-compose-uiTooling = { module = "androidx.compose.ui:ui-tooling", version.ref = "androidx-compose" }
14+
androidx-compose-foundation = { module = "androidx.compose.foundation:foundation", version.ref = "androidx-compose-runtime" }
15+
androidx-compose-material = { module = "androidx.compose.material:material", version.ref = "androidx-compose-runtime" }
16+
androidx-compose-materialIcons = { module = "androidx.compose.material:material-icons-extended", version.ref = "androidx-compose-runtime" }
17+
androidx-compose-runtime = { module = "androidx.compose.runtime:runtime", version.ref = "androidx-compose-runtime" }
18+
androidx-compose-ui = { module = "androidx.compose.ui:ui", version.ref = "androidx-compose-runtime" }
19+
androidx-compose-uiTest = { module = "androidx.compose.ui:ui-test-junit4", version.ref = "androidx-compose-runtime" }
20+
androidx-compose-uiTooling = { module = "androidx.compose.ui:ui-tooling", version.ref = "androidx-compose-runtime" }
2021
androidx-coreKtx = { module = "androidx.core:core-ktx", version = "1.5.0" }
2122
androidx-junit = { module = "androidx.test.ext:junit-ktx", version = "1.1.2" }
2223
androidx-test-rules = { module = "androidx.test:rules", version.ref = "android-test" }
@@ -25,7 +26,7 @@ detekt-gradlePlugin = { module = "io.gitlab.arturbosch.detekt:detekt-gradle-plug
2526
dokka-gradlePlugin = { module = "org.jetbrains.dokka:dokka-gradle-plugin", version = "1.4.32" }
2627
junit = { module = "junit:junit", version = "4.13" }
2728
kotlin-gradlePlugin = { module = "org.jetbrains.kotlin:kotlin-gradle-plugin", version.ref = "kotlin" }
28-
kotlinx-binaryCompatibilityValidator = { module = "org.jetbrains.kotlinx:binary-compatibility-validator", version = "0.5.0" }
29+
kotlinx-binaryCompatibilityValidator = { module = "org.jetbrains.kotlinx:binary-compatibility-validator", version = "0.12.1" }
2930
kotlinx-coroutines = { module = "org.jetbrains.kotlinx:kotlinx-coroutines-android", version = "1.3.6" }
3031
lottie = { module = "com.airbnb.android:lottie", version = "4.1.0"}
3132
poko-gradlePlugin = { module = "dev.drewhamilton.poko:poko-gradle-plugin", version.ref = "poko" }

0 commit comments

Comments
 (0)