Created
September 17, 2019 07:43
-
-
Save tkis/3c2624c6c5f7108c69225c571615b6f2 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private fun restartApplication() { | |
val i = baseContext.packageManager.getLaunchIntentForPackage(baseContext.packageName)!! | |
i.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP) | |
startActivity(i) | |
System.exit(0) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment