1
我想讓動畫在另一個動畫結束後運行,在幾個論壇中我找到了相同的答案,使用setAnimationListener,但是我一直收到找不到符號的錯誤,怎麼了?到Animation
找不到符號方法setAnimationListener
AnimationDrawable
documentation
你正在尋找的一個屬於:
public class Juego extends Activity
{
private AnimationDrawable animacion, loop;
private MediaPlayer miPlayer;
private int order = 1;
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_juego);
ImageView video = (ImageView)findViewById(R.id.secuencia);
video.setBackgroundResource(R.drawable.animation_drawable_start);
animacion = (AnimationDrawable)video.getBackground();
animacion.start();
animacion.setAnimationListener(new AnimationListener() {
@Override
public void onAnimationStart(Animation animation) {
}
@Override
public void onAnimationRepeat(Animation animation) {
}
@Override
public void onAnimationEnd(Animation animation) {
}
});
}
謝謝,你是對的.. –