btn1.setOnClickListener(new MyClickListener());
btn2.setOnClickListener(new MyClickListener());
这样实现貌似更简单吧
public void onClick(View v) {
// TODO Auto-generated method stub
switch (v.getId()) {
case R.id.button1: xxxxx;break;
case R.id.button2: xxxxx:break;...........
}
btn2.setOnClickListener(new MyClickListener());
这样实现貌似更简单吧
public void onClick(View v) {
// TODO Auto-generated method stub
switch (v.getId()) {
case R.id.button1: xxxxx;break;
case R.id.button2: xxxxx:break;...........
}
2016-04-26
用的android studio,输一样的代码,为什么会提示acTextView是unknown class??
2016-04-26