Replace OnGestureListener with SimpleOnGestureListener

This commit is contained in:
Alexander Sytnyk 2017-11-08 13:25:08 +02:00
parent ec612db57d
commit 9bd03ec9e9

View file

@ -209,36 +209,11 @@ public class MapMarkersLayer extends OsmandMapLayer implements IContextMenuProvi
this.view = view;
handler = new Handler();
initUI();
longTapDetector = new GestureDetector(view.getContext(), new GestureDetector.OnGestureListener() {
@Override
public boolean onDown(MotionEvent e) {
return false;
}
@Override
public void onShowPress(MotionEvent e) {
}
@Override
public boolean onSingleTapUp(MotionEvent e) {
return false;
}
@Override
public boolean onScroll(MotionEvent e1, MotionEvent e2, float distanceX, float distanceY) {
return false;
}
longTapDetector = new GestureDetector(view.getContext(), new GestureDetector.SimpleOnGestureListener() {
@Override
public void onLongPress(MotionEvent e) {
cancelFingerAction();
}
@Override
public boolean onFling(MotionEvent e1, MotionEvent e2, float velocityX, float velocityY) {
return false;
}
});
}