Created
August 8, 2020 05:22
-
-
Save MrCrambo/502a0e7974d29306a768d27f143b6157 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class GestureListener implements GestureDetector.OnGestureListener, GestureDetector.OnDoubleTapListener | |
{ | |
@Override | |
public boolean onSingleTapConfirmed(MotionEvent e) | |
{ | |
// Do smth with single tap | |
} | |
@Override | |
public boolean onDoubleTapEvent(MotionEvent e) | |
{ | |
// Do smth with double tap | |
} | |
@Override | |
public boolean onDown(MotionEvent e) | |
{ | |
// Do smth when the users finger is down | |
} | |
@Override | |
public boolean onSingleTapUp(MotionEvent e) | |
{ | |
// Do smth when the single tap is finished | |
} | |
@Override | |
public boolean onScroll(MotionEvent e1, MotionEvent e2, float distanceX, float distanceY) | |
{ | |
// Do smth when the scroll on screen happens | |
} | |
@Override | |
public void onLongPress(MotionEvent e) | |
{ | |
// Do smth when the long press happens | |
} | |
@Override | |
public boolean onFling(MotionEvent e1, MotionEvent e2, float velocityX, float velocityY) | |
{ | |
// Do smth when the fling happens | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment