I override the onTouchEvent method of Activty. In this method i would like to listen to actions: touch and click and give them two different reactions. The problem is when i test my app in emulator, everything works fine. But not in device. As in device, when i just click a button, i don't just get ACTION_DOWN and ACTION_UP but a few ACTION_MOVE signals after ACTION_DOWN.
Asked
Active
Viewed 435 times
1
-
Answered here: [How to distinguish between move and click in onTouchEvent()?](http://stackoverflow.com/questions/9965695/how-to-distinguish-between-move-and-click-in-ontouchevent) – Jonik Dec 09 '13 at 19:09
1 Answers
1
Instead of overriding the TouchEvent on your Activity, assign a listener to the Button itself.
View view = getViewById(R.id.entire_view);
view.setOnTouchListener( ...

Paul Nikonowicz
- 3,883
- 21
- 39