Do not create new task

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
This commit is contained in:
Arnau Mora 2024-06-25 11:59:48 +02:00 committed by Ricki Hirner
parent c2cca01b3b
commit c7b18b1f41

View File

@ -64,9 +64,7 @@ class IntroActivity : AppCompatActivity() {
*/
object Contract: ActivityResultContract<Unit?, Boolean>() {
override fun createIntent(context: Context, input: Unit?): Intent =
Intent(context, IntroActivity::class.java).apply {
flags = Intent.FLAG_ACTIVITY_NEW_TASK or Intent.FLAG_ACTIVITY_CLEAR_TASK
}
Intent(context, IntroActivity::class.java)
override fun parseResult(resultCode: Int, intent: Intent?): Boolean {
return resultCode == Activity.RESULT_CANCELED