diff --git a/app/src/main/kotlin/rasel/lunar/launcher/LauncherActivity.kt b/app/src/main/kotlin/rasel/lunar/launcher/LauncherActivity.kt index 351b547..b48b6c0 100644 --- a/app/src/main/kotlin/rasel/lunar/launcher/LauncherActivity.kt +++ b/app/src/main/kotlin/rasel/lunar/launcher/LauncherActivity.kt @@ -295,6 +295,7 @@ internal class LauncherActivity : AppCompatActivity() { }, delay, TimeUnit.SECONDS) Executors.newSingleThreadScheduledExecutor().schedule({ + //de574a260b1f474d99955729241909 mWorkManager?.cancelAllWorkByTag(OpenWeatherGetter.TAG) mWorkManager?.enqueueUniquePeriodicWork( OpenWeatherGetter.TAG, ExistingPeriodicWorkPolicy.CANCEL_AND_REENQUEUE, diff --git a/app/src/main/kotlin/rasel/lunar/launcher/home/LauncherHome.kt b/app/src/main/kotlin/rasel/lunar/launcher/home/LauncherHome.kt index f43b635..faf13e2 100644 --- a/app/src/main/kotlin/rasel/lunar/launcher/home/LauncherHome.kt +++ b/app/src/main/kotlin/rasel/lunar/launcher/home/LauncherHome.kt @@ -312,7 +312,7 @@ internal class LauncherHome : Fragment() { e.printStackTrace() } - mNotificationResult = WorkersDb.getRealm().query().sort("postTime",Sort.DESCENDING).find() + mNotificationResult = WorkersDb.getRealm().query().sort("postTime",Sort.DESCENDING).distinct("pkgName").find() noticeJob = CoroutineScope(Dispatchers.Default).launch { mNotificationResult?.asFlow()?.collect { changes: ResultsChange -> // BLog.LOGE("changes >>> ${changes}") diff --git a/app/src/main/res/layout/launcher_home.xml b/app/src/main/res/layout/launcher_home.xml index 1650d36..b27a45c 100644 --- a/app/src/main/res/layout/launcher_home.xml +++ b/app/src/main/res/layout/launcher_home.xml @@ -77,7 +77,7 @@ app:layout_constraintLeft_toLeftOf="parent" app:layout_constraintRight_toRightOf="parent" app:layout_constraintTop_toBottomOf="@+id/time" - /> + /> + + +