Skip to content

Commit

Permalink
fix: remove extra getActivityList()
Browse files Browse the repository at this point in the history
  • Loading branch information
RichardLuo0 committed Feb 2, 2025
1 parent cd46d37 commit 73c4a04
Showing 1 changed file with 0 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -69,16 +69,6 @@ class IconVariantVM(app: Application) : AndroidViewModel(app) {
if (basePack.isEmpty()) return
isLoading = true
withContext(Dispatchers.IO) {
val newIcons = mutableMapOf<ComponentName, AppIconInfo>()
context
.getSystemService(Context.LAUNCHER_APPS_SERVICE)
.asType<LauncherApps>()
.getActivityList(null, Process.myUserHandle())
.forEach { info ->
val cn = info.componentName
newIcons[cn] =
AppIconInfo(cn.packageName, info.label.toString(), false, getUpdatedEntryWithPack(cn))
}
icons.putAll(filterAppsVM.loadApps(context, ::getUpdatedEntryWithPack))
}
isLoading = false
Expand Down

0 comments on commit 73c4a04

Please sign in to comment.