From 541073df1339625bc6ce55df29bffe8938f00901 Mon Sep 17 00:00:00 2001 From: Gezim Date: Fri, 26 Dec 2025 18:11:34 +0200 Subject: [PATCH] Wallpaper Setter Fix 5 --- .../gezimos/inkos/ui/compose/SetWallpaper.kt | 97 ++++++++++++------- 1 file changed, 63 insertions(+), 34 deletions(-) diff --git a/app/src/main/java/com/github/gezimos/inkos/ui/compose/SetWallpaper.kt b/app/src/main/java/com/github/gezimos/inkos/ui/compose/SetWallpaper.kt index 4bd0d63..b13a932 100644 --- a/app/src/main/java/com/github/gezimos/inkos/ui/compose/SetWallpaper.kt +++ b/app/src/main/java/com/github/gezimos/inkos/ui/compose/SetWallpaper.kt @@ -15,6 +15,7 @@ import androidx.compose.foundation.layout.padding import androidx.compose.foundation.layout.size import androidx.compose.foundation.layout.width import androidx.compose.material.AlertDialog +import androidx.compose.material.Divider import androidx.compose.material.Icon import androidx.compose.material.icons.Icons import androidx.compose.material.icons.filled.Info @@ -133,11 +134,40 @@ fun SetWallpaper( .padding(24.dp), verticalArrangement = Arrangement.spacedBy(12.dp) ) { - if (hasInkosWallpaper.value) { - Row( - modifier = Modifier.fillMaxWidth(), - horizontalArrangement = Arrangement.spacedBy(12.dp) - ) { + Column( + verticalArrangement = Arrangement.spacedBy(4.dp) + ) { + if (hasInkosWallpaper.value) { + Row( + modifier = Modifier.fillMaxWidth(), + horizontalArrangement = Arrangement.spacedBy(12.dp) + ) { + SetWallpaperOptionButton( + text = "inkOS", + onClick = { + onSetInkOSNoCrop() + hasInkosWallpaper.value = true + }, + fontSize = titleFontSize, + shape = buttonShape, + isPrimary = false, + modifier = Modifier.weight(1f) + ) + + SetWallpaperOptionButton( + text = "✕", + onClick = { + hasInkosWallpaper.value = false + val prefs = Prefs(context) + prefs.inkosWallpaperPath = null + }, + fontSize = titleFontSize, + shape = buttonShape, + isPrimary = false, + modifier = Modifier.width(60.dp) + ) + } + } else { SetWallpaperOptionButton( text = "inkOS", onClick = { @@ -147,44 +177,43 @@ fun SetWallpaper( fontSize = titleFontSize, shape = buttonShape, isPrimary = false, - modifier = Modifier.weight(1f) - ) - - SetWallpaperOptionButton( - text = "✕", - onClick = { - hasInkosWallpaper.value = false - val prefs = Prefs(context) - prefs.inkosWallpaperPath = null - }, - fontSize = titleFontSize, - shape = buttonShape, - isPrimary = false, - modifier = Modifier.width(60.dp) + modifier = Modifier.fillMaxWidth() ) } - } else { + + Text( + text = "Image overlay no crop", + style = SettingsTheme.typography.body, + fontSize = buttonFontSize, + color = Theme.colors.text, + textAlign = TextAlign.Center, + modifier = Modifier.fillMaxWidth() + ) + } + + Divider(color = Theme.colors.text, thickness = 1.dp) + + Column( + verticalArrangement = Arrangement.spacedBy(4.dp) + ) { SetWallpaperOptionButton( - text = "inkOS", - onClick = { - onSetInkOSNoCrop() - hasInkosWallpaper.value = true - }, + text = "Android", + onClick = { showAndroidOptions.value = true }, fontSize = titleFontSize, shape = buttonShape, isPrimary = false, modifier = Modifier.fillMaxWidth() ) - } - SetWallpaperOptionButton( - text = "Android", - onClick = { showAndroidOptions.value = true }, - fontSize = titleFontSize, - shape = buttonShape, - isPrimary = false, - modifier = Modifier.fillMaxWidth() - ) + Text( + text = "Android wallpaper with crop/zoom", + style = SettingsTheme.typography.body, + fontSize = buttonFontSize, + color = Theme.colors.text, + textAlign = TextAlign.Center, + modifier = Modifier.fillMaxWidth() + ) + } } } else { Column(