0
這段代碼應該做點擊按鈕時設置的動畫,等待動畫完成,然後加載新的活動。當我嘗試添加偵聽器時,出現Intent構造函數的錯誤。任何幫助都會很棒。帶意圖的動畫監聽器錯誤
public void onClick (View v) {
switch (v.getId()){
case R.id.buttonStart:
wobble.setAnimationListener(new Animation.AnimationListener() {
@Override
public void onAnimationStart(Animation animation) {
buttonStart.startAnimation(wobble);
}
@Override
public void onAnimationEnd(Animation animation) {
startActivity(new Intent(this,CityRendActivity.class));
}
@Override
public void onAnimationRepeat(Animation animation) {
}
});
break;
}
}
}
以及有哪些誤區? – Leo
而錯誤是? – M4ver1k