don't say much nonsense, first of all the reasons, application to execute too many instructions, start page start will be executed before related methods of application .
OK, the reason is finished, as to how to optimize, then go to the degree, I say here is the launch of the app as soon as possible the start page.
such as the start page is guideactivity
<activity
android:name= ". Guideactivity "
android:screenorientation=" Portrait "
Android:theme=" @ Style/splashtheme ";
<intent-filter>
<action android:name=" Android.intent.action.MAIN " />
<category android:name= "Android.intent.category.LAUNCHER"/>
</intent-filter>
</activity>
Style code:
<style name= "Apptheme.noactionbar" >
<item name= "Windowactionbar" >false</item>
<item name= "Windownotitle" >true</item>
<item name= "Android:windowfullscreen" >true</item>
</style>
<!--Base Application theme. -
<style name= "Splashtheme" parent= "Apptheme.noactionbar" >
<item name= "Android:windowbackground" > @drawable/logo_splash</item>
</style>
OK, end, so easy to optimize performance or change application better, this method is used in the optimization of the slow processing method
It is important to note that after you set the theme, you do not need to set the
Setcontentview (R.LAYOUT.ACTIVITY_GUID);
This can result in duplicate drawing, resulting in unnecessary waste of resources.
App launch optimization, resolve blank pages or lag too long