Questions tagged [android-gesture]

A package in the Android SDK that provides classes to create, recognize, load and save gestures. Gestures are patterns on the touch screen that map to specific functions.

Gesture API

264 questions
9
votes
2 answers

GestureDetector.SimpleOnGestureListener. How do I detect an ACTION_UP event?

Using this mGestureDetector = new GestureDetector(context, new GestureDetector.SimpleOnGestureListener() { @Override public boolean onSingleTapUp(MotionEvent e) { return true; } Only detects for single tap event…
Ersen Osman
  • 6,106
  • 6
  • 34
  • 75
9
votes
2 answers

Canvas Pinch-Zoom to Point Within Bounds

I've been stuck on this problem for eight hours, so I figured it was time to get some help. Before I begin my problem, I'll just let it be known that I've been through this site and Google, and none of the answers I've found have helped. (This is…
Eric
  • 63,873
  • 22
  • 120
  • 135
9
votes
4 answers

Swipe to delete listitem

I would like to implement a swipe gesture to delete rows in a ListView similar to the android notifications. Right now all I have is a ListView with an onTouchListener - that said, I already have swipe detection working. gestureDetector = new…
marcin
  • 259
  • 1
  • 5
  • 13
8
votes
4 answers

fling and pinchzoom for an imageview in one activity

I have an Imageview(like a Magazine page).When i swype in to that image then i want the next image(page).Also want Zoom in and out option for this image.How i can achieve this? Thanks
Jackson Chengalai
  • 3,877
  • 21
  • 39
8
votes
2 answers

Android how to add swipe Gesture on LinearLayout without onDown true

I'm working on Gesture activity in android I used class to detect the swipe action is public class ActivitySwipeDetector implements View.OnTouchListener { static final String logTag = "ActivitySwipeDetector"; private Activity activity; …
Android learner
  • 1,731
  • 4
  • 23
  • 35
8
votes
2 answers

Android "swipe left to right to delete", gesture on list item, ICS Style

I am trying to implement the "swipe left to right to delete" gesture that is present for the notifications in Android ICS and above. I have a listview in my application. I have the gesture detector working. BUT when i swipe from left to right on a…
newbie
  • 979
  • 3
  • 14
  • 27
7
votes
3 answers

Are there open source gesture libraries in Android?

I have defined my own gestures in an Android app. Is this the only way to define gestures? Are there any standard opensource libraries which will already have the gesture's raw file?
Jyotirmoy Sundi
  • 357
  • 1
  • 4
  • 11
7
votes
3 answers

Android. Swipe to back Activity like Telegram

How to swipe to previous activity using gesture and animation like in Telegram and Tinder app?
7
votes
5 answers

How to prevent a double-tap on a ListView?

Is there anyway to prevent double tap on ListView in Android? I found this when i accidentally tapped item on ListView and it opened up two new window. is there any way to prevent it from opening a same window twice.
srbyk1990
  • 381
  • 2
  • 17
7
votes
3 answers

Bezel Gestures with Android

I'm working on an application (on a Galaxy Nexus), and I noticed that Google implemented the "Google Now" application when you swipe from the bottom of the bezel onto the screen (the chrome browser also did this for a while, not sure if it still…
RyanInBinary
  • 1,505
  • 3
  • 19
  • 46
7
votes
3 answers

Custom view with buttons implements OnGestureListener

I've been breaking my head for the last couple of hours, googled the hell out of google and none of the examples on StackOverflow or other places worked for me so here it goes... I have a custom view, that extends LinearLayout and implements…
Lior Iluz
  • 25,118
  • 15
  • 63
  • 107
6
votes
3 answers

Detect swipe using onTouchListener in ScrollView

I'm using the following code to detect swipe in my Activity: getWindow().getDecorView().getRootView().setOnTouchListener(new OnTouchListener() { @Override public boolean onTouch(View v, MotionEvent event) { …
Jainendra
  • 23,305
  • 30
  • 116
  • 165
5
votes
1 answer

Custom swipe animation (Tilt, Card Deck, 3D, etc.)

How can I implement a custom swipe animation instead of the standard horizontal movement? I'm thinking about a mixture of ViewPager (swipe to scroll) and ViewFlipper (custom animation). It's important that the animation gives a live feedback to the…
5
votes
3 answers

Can't see click ripple effect in Android Touch events

I've seen some solutions here, but none of them works for me. I am using View.OnTouchListener class to detect click and drag events in my app code. But that beautiful ripple effect is now gone (perhaps because I am consuming the MotionEvent gestures…
5
votes
0 answers

How to detect edges swipe on android phone for manipulating touch behaviour?

I am implementing GestureDetector.OnGestureListener in Activity, whose overridden onTouchEvent is : public boolean onTouchEvent(MotionEvent event) { //gestureDetector is new GestureDetector(this,this) in Activity's onCreate() …
bharat
  • 95
  • 1
  • 1
  • 8
1
2
3
17 18