Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,9 @@ dependencies {
implementation(libs.compose.ui.toolingPreview)
implementation(libs.compose.runtime.livedata)

implementation(libs.aboutLibs.core)
implementation(libs.aboutLibs.compose)
implementation(libs.aboutLibs.compose.core)
implementation(libs.jodaTime)

implementation(libs.ktor.core)
Expand Down
6 changes: 2 additions & 4 deletions app/src/main/java/at/bitfire/icsdroid/ui/nav/MainApp.kt
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,7 @@ import androidx.core.os.BundleCompat
import androidx.lifecycle.viewmodel.navigation3.rememberViewModelStoreNavEntryDecorator
import androidx.navigation3.runtime.entryProvider
import androidx.navigation3.runtime.rememberNavBackStack
import androidx.navigation3.runtime.rememberSavedStateNavEntryDecorator
import androidx.navigation3.scene.rememberSceneSetupNavEntryDecorator
import androidx.navigation3.runtime.rememberSaveableStateHolderNavEntryDecorator
import androidx.navigation3.ui.NavDisplay
import at.bitfire.icsdroid.MainActivity.Companion.EXTRA_ERROR_MESSAGE
import at.bitfire.icsdroid.MainActivity.Companion.EXTRA_REQUEST_CALENDAR_PERMISSION
Expand Down Expand Up @@ -103,8 +102,7 @@ fun MainApp(

NavDisplay(
entryDecorators = listOf(
rememberSceneSetupNavEntryDecorator(),
rememberSavedStateNavEntryDecorator(),
rememberSaveableStateHolderNavEntryDecorator(),
rememberViewModelStoreNavEntryDecorator()
),
backStack = backStack,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ fun AddSubscriptionScreen(
LaunchedEffect(uiState) {
if (uiState.success) {
// on success, show notification and close activity
Toast.makeText(context, context.getString(R.string.add_calendar_created), Toast.LENGTH_LONG).show()
Toast.makeText(context, R.string.add_calendar_created, Toast.LENGTH_LONG).show()
onBackRequested()
}
uiState.errorMessage?.let {
Expand Down
4 changes: 2 additions & 2 deletions app/src/main/java/at/bitfire/icsdroid/ui/screen/InfoScreen.kt
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ import at.bitfire.icsdroid.service.ComposableStartupService.Companion.FLAG_DONAT
import at.bitfire.icsdroid.ui.partials.ExtendedTopAppBar
import at.bitfire.icsdroid.ui.partials.GenericAlertDialog
import com.mikepenz.aboutlibraries.ui.compose.m3.LibrariesContainer
import com.mikepenz.aboutlibraries.ui.compose.rememberLibraries
import com.mikepenz.aboutlibraries.ui.compose.produceLibraries
import kotlinx.coroutines.runBlocking
import java.util.ServiceLoader

Expand Down Expand Up @@ -104,7 +104,7 @@ fun InfoScreen(
)
}
) { contentPadding ->
val libraries by rememberLibraries {
val libraries by produceLibraries {
resources.openRawResource(R.raw.aboutlibraries).bufferedReader().use { input ->
input.readText()
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ import androidx.compose.runtime.rememberCoroutineScope
import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier
import androidx.compose.ui.graphics.Color
import androidx.compose.ui.platform.LocalContext
import androidx.compose.ui.res.stringResource
import androidx.compose.ui.text.font.FontWeight
import androidx.compose.ui.text.input.ImeAction
Expand Down Expand Up @@ -83,8 +82,6 @@ fun EnterUrlComposable(
onPickFileRequested: () -> Unit,
onSubmit: () -> Unit
) {
val context = LocalContext.current

validationResult?.exception?.let { exception ->
val errorMessage = exception.localizedMessage ?: exception.message ?: exception.toString()
AlertDialog(
Expand All @@ -94,10 +91,11 @@ fun EnterUrlComposable(

val snackbarHostState = remember { SnackbarHostState() }

val addCalendarValidatingString = stringResource(R.string.add_calendar_validating)
LaunchedEffect(isVerifyingUrl) {
if (isVerifyingUrl) {
snackbarHostState.showSnackbar(
context.getString(R.string.add_calendar_validating),
addCalendarValidatingString,
Comment thread
ArnyminerZ marked this conversation as resolved.
duration = SnackbarDuration.Indefinite
)
} else {
Expand Down
39 changes: 18 additions & 21 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
@@ -1,40 +1,40 @@
[versions]
aboutLibs = "12.2.4"
agp = "8.13.0"
androidx-activityCompose = "1.11.0"
aboutLibs = "13.1.0"
agp = "8.13.1"
androidx-activityCompose = "1.12.1"
androidx-appCompat = "1.7.1"
androidx-archCore = "2.2.0"
androidx-core = "1.17.0"
androidx-hilt = "1.3.0"
androidx-lifecycle = "2.9.4"
# should be replaced by androidx-lifecycle once nav3 is stable (probably 2.10.0?)
androidx-lifecycle-nav3 = "2.10.0-alpha04"
androidx-nav3 = "1.0.0-alpha10"
androidx-lifecycle = "2.10.0"
androidx-nav3 = "1.0.0"
androidx-test-junit = "1.3.0"
androidx-test-rules = "1.7.0"
androidx-test-runner = "1.7.0"
androidx-work = "2.10.5"
androidx-work = "2.11.0"
bitfire-cert4android = "41009d4"
bitfire-synctools = "7aa709f6b6"
compose-dialogs = "1.3.0"
compose-material = "1.7.8"
compose-material3 = "1.4.0"
compose-runtime = "1.9.2"
compose-ui = "1.9.2"
datastore = "1.1.7"
compose-runtime = "1.10.0"
compose-ui = "1.10.0"
datastore = "1.2.0"
desugaring = "2.1.5"
hilt = "2.57.2"
joda-time = "2.14.0"
junit = "4.13.2"
kotlin = "2.2.20"
kotlin = "2.2.21"
kotlinx-coroutines = "1.10.2"
kotlinx-serialization-core = "1.9.0"
ksp = "2.2.20-2.0.3"
ktor = "3.3.0"
okhttp = "5.1.0"
room = "2.8.1"
ksp = "2.3.3"
ktor = "3.3.3"
okhttp = "5.3.2"
room = "2.8.4"

[libraries]
aboutLibs-core = { module = "com.mikepenz:aboutlibraries-core", version.ref = "aboutLibs" }
aboutLibs-compose-core = { module = "com.mikepenz:aboutlibraries-compose-core", version.ref = "aboutLibs" }
aboutLibs-compose = { module = "com.mikepenz:aboutlibraries-compose-m3", version.ref = "aboutLibs" }
androidx-activityCompose = { module = "androidx.activity:activity-compose", version.ref = "androidx-activityCompose" }
androidx-appCompat = { module = "androidx.appcompat:appcompat", version.ref = "androidx-appCompat" }
Expand All @@ -46,7 +46,7 @@ androidx-hilt-navigation-compose = { module = "androidx.hilt:hilt-navigation-com
androidx-hilt-work = { module = "androidx.hilt:hilt-work", version.ref = "androidx-hilt" }
androidx-lifecycle-viewmodel = { module = "androidx.lifecycle:lifecycle-viewmodel-ktx", version.ref = "androidx-lifecycle" }
androidx-lifecycle-viewmodel-compose = { module = "androidx.lifecycle:lifecycle-viewmodel-compose", version.ref = "androidx-lifecycle" }
androidx-lifecycle-viewmodel-navigation3 = { module = "androidx.lifecycle:lifecycle-viewmodel-navigation3", version.ref = "androidx-lifecycle-nav3" }
androidx-lifecycle-viewmodel-navigation3 = { module = "androidx.lifecycle:lifecycle-viewmodel-navigation3", version.ref = "androidx-lifecycle" }
androidx-lifecycle-runtime-compose = { module = "androidx.lifecycle:lifecycle-runtime-compose", version.ref = "androidx-lifecycle" }
androidx-navigation3-runtime = { module = "androidx.navigation3:navigation3-runtime", version.ref = "androidx-nav3" }
androidx-navigation3-ui = { module = "androidx.navigation3:navigation3-ui", version.ref = "androidx-nav3" }
Expand Down Expand Up @@ -75,15 +75,12 @@ jodaTime = { module = "joda-time:joda-time", version.ref = "joda-time" }
junit = { module = "junit:junit", version.ref = "junit" }
kotlinx-coroutines = { module = "org.jetbrains.kotlinx:kotlinx-coroutines-android", version.ref = "kotlinx-coroutines" }
kotlinx-serialization-core = { module = "org.jetbrains.kotlinx:kotlinx-serialization-core", version.ref = "kotlinx-serialization-core" }
okhttp-base = { module = "com.squareup.okhttp3:okhttp", version.ref = "okhttp" }
okhttp-coroutines = { module = "com.squareup.okhttp3:okhttp-coroutines", version.ref = "okhttp" }
okhttp-brotli = { module = "com.squareup.okhttp3:okhttp-brotli", version.ref = "okhttp" }
okhttp-mockwebserver = { module = "com.squareup.okhttp3:mockwebserver", version.ref = "okhttp" }
room-base = { module = "androidx.room:room-ktx", version.ref = "room" }
room-compiler = { module = "androidx.room:room-compiler", version.ref = "room" }

[plugins]
aboutLibs = { id = "com.mikepenz.aboutlibraries.plugin", version.ref = "aboutLibs" }
aboutLibs = { id = "com.mikepenz.aboutlibraries.plugin.android", version.ref = "aboutLibs" }
android-application = { id = "com.android.application", version.ref = "agp" }
compose-compiler = { id = "org.jetbrains.kotlin.plugin.compose", version.ref = "kotlin" }
hilt = { id = "com.google.dagger.hilt.android", version.ref = "hilt" }
Expand Down