Properly skip login activity if already logged in

后端 未结 5 1350
终归单人心
终归单人心 2021-01-31 03:55

My launcher icon currently starts the login activity. I\'ve stored the logged in status in SharedPreferences. Is there any way to properly skip the login activi

5条回答
  •  一向
    一向 (楼主)
    2021-01-31 04:32

    You can also check for login status during your splash screen activity if you have one. Splash screens are great for letting users know the app hasn't stalled when it's loading and can also be used to redirect the app to the appropriate screen.

    I followed this great guide my first time making one: https://www.bignerdranch.com/blog/splash-screens-the-right-way/

提交回复
热议问题