I've two activities, one is the
SplashActivity
and the other is MainActivity
, an activity containing a webview.
I need to load the webview when showing the splash screen. So I'm looking for a way to load the MainActivity in background in SplashActivity::onCreate()
;
If intend is directly called, the MainActivity is immediately brought to the front, as well as a stuck in the webview.
I looked up a lot of solutions about splash screen like this
. However they don't initialize the MainActivity until the splash time expires.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…