android - google play sevice mainactivity -


i've implemented google play services demo code found @ url:

https://github.com/kpbird/google-play-service/blob/master/src/com/kpbird/googleplayservice/mainactivity.java

and works. if function getaccountnames() called within oncreate, application momentarialy flashes before loading set content view. it's there 2 activity views being initiatied.

@override protected void oncreate(bundle savedinstancestate) {     super.oncreate(savedinstancestate);     setcontentview(r.layout.activity_main);     txtaccount = (textview) findviewbyid(r.id.txtaccount);     txttoken = (textview) findviewbyid(r.id.txttoken);     getaccountnames(); } 

why placing getaccountnames() in oncreate create visual effect when application launches.


Comments

Popular posts from this blog

c# - DetailsView in ASP.Net - How to add another column on the side/add a control in each row? -

javascript - firefox memory leak -

Trying to import CSV file to a SQL Server database using asp.net and c# - can't find what I'm missing -