最終更新:2013-03-27 (水) 18:57:20 (4041d)
View.onTouchEvent
Top / View.onTouchEvent
Called when a touch screen motion event occurs.
boolean onTouchEvent(MotionEvent event)
メモ
- Implement this method to handle touch screen motion events.
返り値
- True if the event was handled, false otherwise.
- デフォルトはfalse
- trueを返すとイベントを消費したとみなされて他のコンポーネントにイベントは伝わらない
GestureDetector.onTouchEvent
- In the View.onTouchEvent(MotionEvent) method ensure you call GestureDetector.onTouchEvent(MotionEvent).
- The methods defined in your callback will be executed when the events occur.
関連
- Activity.onTouchEvent - Viewでタッチイベントが消費されなかった場合に呼ばれる。