diff --git a/app/src/main/java/com/topjohnwu/magisk/arch/BaseMainActivity.kt b/app/src/main/java/com/topjohnwu/magisk/arch/BaseMainActivity.kt index c3f4981c7..16ddf444a 100644 --- a/app/src/main/java/com/topjohnwu/magisk/arch/BaseMainActivity.kt +++ b/app/src/main/java/com/topjohnwu/magisk/arch/BaseMainActivity.kt @@ -59,7 +59,7 @@ abstract class BaseMainActivity doPreload = false if (isRunningAsStub) { // Re-launch main activity without splash theme - recreate() + relaunch() } else { showMainUI(savedInstanceState) } diff --git a/app/src/main/java/com/topjohnwu/magisk/core/base/BaseActivity.kt b/app/src/main/java/com/topjohnwu/magisk/core/base/BaseActivity.kt index c39cc1344..a206b1592 100644 --- a/app/src/main/java/com/topjohnwu/magisk/core/base/BaseActivity.kt +++ b/app/src/main/java/com/topjohnwu/magisk/core/base/BaseActivity.kt @@ -69,4 +69,9 @@ abstract class BaseActivity : AppCompatActivity() { startActivity(Intent().setComponent(intent.component)) finish() } + + fun relaunch() { + startActivity(Intent(intent).setFlags(0)) + finish() + } }