Update readme, optimize UI

This commit is contained in:
BinTianqi
2025-09-07 13:34:42 +08:00
parent 765b1ea790
commit e7c7a3b3c6
5 changed files with 22 additions and 6 deletions

View File

@@ -57,6 +57,14 @@ Solutions:
> [!NOTE]
> Some systems have features such as app cloning and children space, which are usually users.
#### Device owner is already set
```text
java.lang.IllegalStateException: Trying to set the device owner (com.bintianqi.owndroid/.Receiver), but device owner (xxx) is already set.
```
Only 1 device owner can exist on a device. Please deactivate the existing device owner first.
### MIUI & HyperOS
```text

View File

@@ -57,6 +57,14 @@ java.lang.IllegalStateException: Not allowed to set the device owner because the
> [!NOTE]
> 一些系统有应用克隆、儿童空间等功能,它们通常是用户。
#### Device owner 已存在
```text
java.lang.IllegalStateException: Trying to set the device owner (com.bintianqi.owndroid/.Receiver), but device owner (xxx) is already set.
```
一个设备只能存在一个device owner请先停用已存在的device owner。
### MIUI & HyperOS
```text

View File

@@ -29,6 +29,7 @@ import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.layout.ime
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.layout.size
import androidx.compose.foundation.layout.width
import androidx.compose.foundation.lazy.LazyItemScope
import androidx.compose.foundation.lazy.items
import androidx.compose.foundation.rememberScrollState
@@ -124,7 +125,7 @@ fun LazyItemScope.ApplicationItem(info: AppInfo, onClear: () -> Unit) {
Modifier.fillMaxWidth().padding(horizontal = 8.dp, vertical = 6.dp).animateItem(),
Arrangement.SpaceBetween, Alignment.CenterVertically
) {
Row(Modifier.fillMaxWidth(0.87F), verticalAlignment = Alignment.CenterVertically) {
Row(Modifier.weight(1F), verticalAlignment = Alignment.CenterVertically) {
Image(
painter = rememberDrawablePainter(info.icon), contentDescription = null,
modifier = Modifier.padding(start = 12.dp, end = 18.dp).size(30.dp)

View File

@@ -116,7 +116,6 @@ import com.topjohnwu.superuser.Shell
import kotlinx.coroutines.delay
import kotlinx.coroutines.launch
import kotlinx.serialization.Serializable
import kotlinx.serialization.encodeToString
import kotlinx.serialization.json.Json
@Serializable data class WorkModes(val canNavigateUp: Boolean)
@@ -549,15 +548,15 @@ fun DhizukuServerSettingsScreen(onNavigateUp: () -> Unit) {
.padding(8.dp, 8.dp, 0.dp, 8.dp),
Arrangement.SpaceBetween, Alignment.CenterVertically
) {
Row(verticalAlignment = Alignment.CenterVertically) {
Row(Modifier.weight(1F), verticalAlignment = Alignment.CenterVertically) {
Image(
rememberDrawablePainter(info.loadIcon(pm)), null,
Modifier
.padding(end = 16.dp)
.size(50.dp)
.size(45.dp)
)
Column {
Text(info.loadLabel(pm).toString(), style = typography.titleLarge)
Text(info.loadLabel(pm).toString(), style = typography.titleMedium)
Text(name, Modifier.alpha(0.7F), style = typography.bodyMedium)
}
}

View File

@@ -161,7 +161,7 @@ fun UserRestrictionOptionsScreen(
Modifier.fillMaxWidth().padding(15.dp, 6.dp),
Arrangement.SpaceBetween, Alignment.CenterVertically
) {
Row(Modifier.fillMaxWidth(0.8F), verticalAlignment = Alignment.CenterVertically) {
Row(Modifier.weight(1F), verticalAlignment = Alignment.CenterVertically) {
Icon(painterResource(restriction.icon), null, Modifier.padding(start = 6.dp, end = 16.dp))
Column {
Text(stringResource(restriction.name), style = typography.titleMedium)