Interview Questions
You can use the following questions as a guide to consolidate your understanding of this chapter:
- What are some differences between
onTouchEvent()
andonTouch()
? - What manifest tag should you use to indicate to Android Market that your application requires a touch screen?
- If you want a view to continue to receive touch events in the current touch sequence, do you return
true
orfalse
from the callback? - What is the first action you’ll receive in a touch sequence?
- What is the last action you’ll receive?
- True or false: a
MotionEvent
object is created for every single touch event. - What precautions should you take when using
getSize()
andgetPressure()
withMotionEvent
objects? - When is it appropriate to recycle a
MotionEvent
object? ...
Get Pro Android 4 now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.