This commit is contained in:
Li ZongYing
2024-03-07 19:37:03 +08:00
parent 0ebc166acc
commit 00e6c8d66e
23 changed files with 402 additions and 216 deletions
@@ -7,8 +7,7 @@ import android.content.Intent
class BootReceiver : BroadcastReceiver() {
override fun onReceive(context: Context, intent: Intent) {
val sp = context.getSharedPreferences("MainActivity", Context.MODE_PRIVATE)
if (sp.getBoolean(MainActivity.BOOT_STARTUP, true)) {
if (SP.bootStartup) {
context.startActivity(
Intent(context, MainActivity::class.java)
.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK)