Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

One time Android setup screen?

Tags:

android

I'm trying to create a setup activity for my Android application which my users would see the first time they opened the app, but never again unless they wanted to redo the setup. How do I create this setup activity as the first activity without giving it MAIN/LAUNCHER intent-filters? (I want to use those for my home activity.)

like image 682
jondelmil Avatar asked Dec 18 '22 00:12

jondelmil


1 Answers

If the onCreate method of an Activity launches another activity, it appears as though the first activity doesn't show.

So, make your real first activity the main/launcher activity.

In the onCreate method of that first activity have a check for whatever setup config should be present.

If the setup is not configured, start up the Setup activity.

Otherwise, the first activity will show.

like image 84
Cheryl Simon Avatar answered Dec 28 '22 06:12

Cheryl Simon