lets not list microG either

This commit is contained in:
tibbi 2022-09-25 17:08:42 +02:00
parent eaa9d091c3
commit 3b59ad1a7f
1 changed files with 3 additions and 2 deletions

View File

@ -347,15 +347,16 @@ class MainActivity : SimpleActivity(), FlingListener {
intent.addCategory(Intent.CATEGORY_LAUNCHER)
val simpleLauncher = applicationContext.packageName
val microG = "com.google.android.gms"
val list = packageManager.queryIntentActivities(intent, PackageManager.PERMISSION_GRANTED)
for (info in list) {
val componentInfo = info.activityInfo.applicationInfo
val label = info.loadLabel(packageManager).toString()
val packageName = componentInfo.packageName
if (packageName == simpleLauncher) {
if (packageName == simpleLauncher || packageName == microG) {
continue
}
val label = info.loadLabel(packageManager).toString()
val drawable = getDrawableForPackageName(packageName) ?: continue
val placeholderColor = calculateAverageColor(drawable.toBitmap())