Tecnologia do Blogger.
RSS

Re: [androidbrasil-dev] Re: Splaash Screen alterando background

Olha, no meu app eu trabalho com AnimationDrawable, 

eu basicamente crio um drawable:

<?xml version="1.0" encoding="utf-8"?>
<animation-list xmlns:android="http://schemas.android.com/apk/res/android"
    android:oneshot="false" >

    <item
        android:drawable="@drawable/img_weel_1"
        android:duration="100"/>
    <item
        android:drawable="@drawable/img_weel_2"
        android:duration="100"/>
    <item
        android:drawable="@drawable/img_weel_3"
        android:duration="100"/>
    <item
        android:drawable="@drawable/img_weel_4"
        android:duration="100"/>
    <item
        android:drawable="@drawable/img_weel_5"
        android:duration="100"/>
    <item
        android:drawable="@drawable/img_weel_6"
        android:duration="100"/>
    <item
        android:drawable="@drawable/img_weel_7"
        android:duration="100"/>
    <item
        android:drawable="@drawable/img_weel_8"
        android:duration="100"/>
    <item
        android:drawable="@drawable/img_weel_9"
        android:duration="100"/>

</animation-list>

No codigo:

private ImageView imgWheel;
private AnimationDrawable frameAnimation;

imgWheel = (ImageView) findViewById(R.id.img_wheel);
imgWheel.setBackgroundResource(R.drawable.SEU_DRAWABLE_SPLASH);
frameAnimation = (AnimationDrawable) imgWheel.getBackground();
imgWheel.post(new Runnable(){
  public void run(){
  frameAnimation.start();
  }
});


Dá uma pesquisada sobre isso, não sei se é a melhor solução, mas no meu app ele mostra uma animaçãozinha.


Em 8 de agosto de 2013 09:27, luciofm <luciofm@gmail.com> escreveu:
no setContentView seta a view já com a primeira imagem,

depois dentro do onCreate coloca um new Handler.postDelayed(runnable, 5000) e no runnable troca o imageview para a segunda imagem

Lúcio Maciel
luciofm@gmail.com


2013/8/8 Wellison Souza <wellison.maceio@gmail.com>
Galera, quanto ao tempo é exigência da ONG, como vai ser um app free, tem que ressaltar os colaboradores.
mas até agora nao consegui fazer isso ... alguém me ajuda?

Em quinta-feira, 8 de agosto de 2013 08h53min19s UTC-3, Andre Souza escreveu:
meu splash tem 3 segundos e ja acho muito uhahuauhauha


Em 8 de agosto de 2013 08:47, Maicon Strey <mst...@gmail.com> escreveu:
o tempo máximo que acharia aceitável seria 2 segundos para cada tela.


Maicon Strey
Novo Hamburgo - RS - Brasil
------------------
------------------
Linux user: #525086


2013/8/7 Rudson Lima <rudso...@gmail.com>

Concordo com o Ricardo

Em 07/08/2013 23:05, "Wellison Souza" <welliso...@gmail.com> escreveu:



Em quarta-feira, 7 de agosto de 2013 22h40min01s UTC-3, Wellison Souza escreveu:
Boa noite pessoal,
estou tentando criar um splaash com 2 imagens no background ... a primeira já está setada no xml a segunda eu gostaria que fosse alterada depois de 5 segundos.
Tentei usar Thread mas nao consegui ... 
Então o splaash vai durar 10 segundos, 5 na primeira imagem e 5 na segunda, depois disso ele vai para a view principal.
Alguém pode me falar como faço isso?

--
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-...@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.
 
 

--
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-...@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.
 
 

--
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-...@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.



--
André Luiz de Oliveira Souza
Engenheiro da Computação
Pós-graduando em Desenvolvimento de Software com ênfase em Java Corporativo

--
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.
 
 

--
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.



--
André Luiz de Oliveira Souza
Engenheiro da Computação
Pós-graduando em Desenvolvimento de Software com ênfase em Java Corporativo

--
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.

  • Digg
  • Del.icio.us
  • StumbleUpon
  • Reddit
  • RSS

0 comentários:

Postar um comentário