OnTouch and onTouchEvent methods, ontouchevent
1. onTouch () method
It is defined in the onTouchListener () interface of the view. When a view is bound with an onTouchListener and triggered by a touch event, the onTouch () method is called to put the view on your fingers, will be called once)
2. onTouchEvent
Is the activity method. After the onTouchEvent method of the activity is rewritten, the screen will be triggered when there is a touch event. This method will be called (put your finger on the activity, will be called continuously)
3. Transfer of touch events
If a TextView is placed in an activity clock and set to fill_parent, The onTouch () method is executed when the finger is put on.
If onTouch () returns true, it indicates that the processing is complete, and the touch event will not be passed to the activity, that is, the onTouchEvent () method will not be called,
If the onTouch () method returns false, it indicates that the event is not processed completely. In this case, the touch event is passed to the activity, that is, the onTouchEvent () method is called.