Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 0ef94b59 authored by Fahim Salam Chowdhury's avatar Fahim Salam Chowdhury 👽
Browse files

5560-rnd_handle_mail_account_by_accountManager_in_background

parent e1ec9119
Loading
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -9,6 +9,7 @@
package foundation.e.accountmanager.ui

import android.accounts.AccountManager
import android.content.ComponentName
import android.content.ContentResolver
import android.content.Intent
import android.content.SyncStatusObserver
@@ -44,6 +45,12 @@ class AccountsActivity: AppCompatActivity(), NavigationView.OnNavigationItemSele
        super.onCreate(savedInstanceState)
        settings = Settings.getInstance(this)

        val intent = Intent()
        intent.action = "foundation.e.accountmanager.account.create"
        intent.addFlags(Intent.FLAG_INCLUDE_STOPPED_PACKAGES)
        intent.component = ComponentName("foundation.e.mail", "com.fsck.k9.OnAccountCreationReceiver")
        applicationContext.sendBroadcast(intent)

        setContentView(R.layout.activity_accounts)
        setSupportActionBar(toolbar)