[Animation1.java]
import android.view.animation.Animation;
import android.view.animation.AnimationUtils;
public class Animation1 extends Activity implements View.OnClickListener {
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.animation_1);
View loginButton = findViewById(R.id.login);
loginButton.setOnClickListener(this);
}
public void onClick(View v) {
Animation shake = AnimationUtils.loadAnimation(this, R.anim.shake);
findViewById(R.id.pw).startAnimation(shake);
}
}
'old > API_Demo' 카테고리의 다른 글
View_AutoComplete_ScreenBottom (0) | 2010.04.02 |
---|---|
View_AutoComplete_ScreenTop (0) | 2010.04.02 |
Views_Animation_Push (0) | 2010.03.26 |
Views_Animation_Interpolators (0) | 2010.03.26 |
Views_Animation_3DTransition (0) | 2010.03.26 |