안드로이드 개발 질문/답변
(글 수 45,052)
package exam.Zoom2;
import android.app.Activity;
import android.os.Bundle;
import android.util.Log;
import android.view.MotionEvent;
import android.view.View;
import android.view.View.OnTouchListener;
import android.widget.ImageView;
import android.widget.RelativeLayout;
import android.widget.ScrollView;
import android.widget.TextView;
public class Zoom2 extends Activity implements OnTouchListener {ScrollView mSv;
RelativeLayout mRe;
ImageView mIv;
TextView mTv;
TextView mTv2;
TextView mTv3;
TextView mTv4;
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {super.onCreate(savedInstanceState);
setContentView(R.layout.main);
mSv = (ScrollView)findViewById(R.id.scroll);
mRe = (RelativeLayout)findViewById(R.id.relative);
mIv = (ImageView)findViewById(R.id.iv);
mTv = (TextView)findViewById(R.id.tv);
mTv2 = (TextView)findViewById(R.id.tv2);
// mTv3 = (TextView)findViewById(R.id.tv3);
// mTv4 = (TextView)findViewById(R.id.tv4);
mSv.setOnTouchListener(this);
}
@Override
public boolean onTouch(View v, MotionEvent event) {// TODO Auto-generated method stub
switch (event.getAction() & MotionEvent.ACTION_MASK) {case MotionEvent.ACTION_DOWN:
Log.i("다운","");break;
case MotionEvent.ACTION_POINTER_DOWN :
Log.i("두번째다운","");break;
case MotionEvent.ACTION_MOVE:
Log.i("무브무브","");break;
case MotionEvent.ACTION_UP :
Log.i("업","");break;
case MotionEvent.ACTION_POINTER_UP:
Log.i("두번째업","");break;
}
return true;
}
}
이벤트가 안들어오는데요..
무엇이 문제 확인좀해주세요..
아 답답해죽겠는데요
됐다안됏따
지금은 스크롤뷰에 되어있는데..
다른곳에 해도..증상은 똑같네요..




엥..
이거 로그가 안찍히는데
토스트는 찍히네요.~?~?~??ㅡㅡ