0

I want to show a dialog (kind of splash screen) when my application is opened. Therefore I put a create and show dialog into onCreate(). The dialog opens indeed but first, the empty activity (white background) is shown.

There must be a possibility to prevent that empty screen to be shown? A lot of apps have a behaviour like that. I would like to have the dialog as the actual first screen to be shown to the user.

nob
  • 1,067
  • 1
  • 11
  • 18
  • http://stackoverflow.com/questions/6159702/android-show-spinning-wheel-dialog-while-loading-data – Dheeresh Singh Jun 30 '12 at 17:15
  • Have a look at this http://blog.iangclifton.com/2011/01/01/android-splash-screens-done-right/ – vasart Jun 30 '12 at 17:16
  • code is here: https://github.com/nobnago/Anki-Android/blob/da0f20af28865067821f29c21a23e83049d1af04/src/com/ichi2/anki/DeckPicker.java – nob Jun 30 '12 at 17:36
  • but it's not a matter of things beeing done before the dialog is shown. The problem is, that even if I show the dialog directly after super.onCreate(savedInstanceState) and before setContentView(), there will a an (empty) activity first. So I need to get rid of that – nob Jun 30 '12 at 17:37

1 Answers1

1

it would be better if we have code to see tasks taking time as per general solution

Android SplashScreen

Show spinning wheel dialog while loading data on Android

http://blog.iangclifton.com/2011/01/01/android-splash-screens-done-right/

Community
  • 1
  • 1
Dheeresh Singh
  • 15,643
  • 3
  • 38
  • 36
  • – nob Jul 01 '12 at 07:54