Revert "Add cloned profile support"

This reverts commit 1d2798ba4f.

Reopen #1364
This commit is contained in:
MM20
2025-10-24 20:14:10 +02:00
parent b16f5c4861
commit ede17ad0d8
4 changed files with 2 additions and 20 deletions

View File

@@ -1,7 +1,6 @@
package de.mm20.launcher2.badges.providers
import androidx.compose.material.icons.Icons
import androidx.compose.material.icons.rounded.ContentCopy
import androidx.compose.material.icons.rounded.Lock
import androidx.compose.material.icons.rounded.Work
import de.mm20.launcher2.badges.Badge
@@ -34,7 +33,6 @@ class ProfileBadgeProvider : BadgeProvider, KoinComponent {
when(it?.type) {
Profile.Type.Work -> WorkProfile
Profile.Type.Private -> PrivateProfile
Profile.Type.Cloned -> ClonedProfile
else -> null
}
}
@@ -52,9 +50,5 @@ class ProfileBadgeProvider : BadgeProvider, KoinComponent {
private val PrivateProfile = Badge(
icon = BadgeIcon(Icons.Rounded.PrivateSpace)
)
private val ClonedProfile = Badge(
icon = BadgeIcon(Icons.Rounded.ContentCopy)
)
}
}

View File

@@ -276,7 +276,6 @@ internal class SearchServiceImpl(
val standardProfile = profiles.find { it.type == Profile.Type.Personal }
val workProfile = profiles.find { it.type == Profile.Type.Work }
val privateSpace = profiles.find { it.type == Profile.Type.Private }
val clonedProfile = profiles.find { it.type == Profile.Type.Cloned }
appRepository.search("", false)
.withCustomLabels(customAttributesRepository)
.map { apps ->
@@ -288,9 +287,6 @@ internal class SearchServiceImpl(
standardProfile != null && app.user == standardProfile.userHandle -> standardProfileApps.add(
app
)
clonedProfile != null && app.user == clonedProfile.userHandle -> standardProfileApps.add(
app
)
workProfile != null && app.user == workProfile.userHandle -> workProfileApps.add(
app