Isso irá te ajudar..
http://stackoverflow.com/questions/6525698/how-to-use-onsavedinstancestate-example-please
http://stackoverflow.com/questions/6525698/how-to-use-onsavedinstancestate-example-please
Em 22 de fevereiro de 2014 22:21, Carlos Augusto Duarte <superfotoss@gmail.com> escreveu:
Calma galera... Vou explicar! hehe--
Estou com um problema no desenvolvimento.
Preciso abrir uma activity e "popular" uma ListView com alguns itens padrão.
O onCreate() desta activity está chamando meu método popularListView().
Enquanto eu estou com a activity aberta, posso adicionar mais itens na ListView. O problema é que no simples fato de girar o telefone, ele chama o método onCreate() novamente, consequentemente chamando novamente o meu método popularListView().
Tem como fazer que o meu método seja chamado apenas uma vez enquanto a activity não dor destruída (indiferente de quantas vezes eu gire o telefone)?
Grande abraço.
You received this message because you are subscribed to the Google Groups "Android Brasil - Dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to androidbrasil-dev+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
--
Rudson Lima ( live-O )
Desenvolvedor Android - Web Service C# - SQL Server - Delphi+55 85 87050560 - Fortaleza-ce
You received this message because you are subscribed to the Google Groups "Android Brasil - Dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to androidbrasil-dev+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.






0 comentários:
Postar um comentário