This week's book giveaway is in the Android forum.
We're giving away four copies of Head First Android and have Dawn & David Griffiths on-line!
See this thread for details.
The moose likes Android and the fly likes GestureListener on gridview Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Head First Android this week in the Android forum!
JavaRanch » Java Forums » Mobile » Android
Bookmark "GestureListener on gridview" Watch "GestureListener on gridview" New topic
Author

GestureListener on gridview

chetan dhumane
Ranch Hand

Joined: Jan 07, 2009
Posts: 636

Does any one has the code of GestureListener on gridview items .because i should perform left ,right flig on gridview and long press and touch and click on gridview items. .while long press on the items in grid view i should get the x,y coordinate values,but
gridview.setOnItemLongClickListener(new OnItemLongClickListener()
{

@Override
public boolean onItemLongClick(AdapterView<?> arg0, View arg1,
int arg2, long arg3) {}

this long clickable does not have parameters of motionevent...


can any one tell how to add gesturelistener on gridview


Author @ http://www.ideasforideas.org/
Moody blogger who do not like to behave like target setting machines work.
David Bei
Greenhorn

Joined: Aug 30, 2010
Posts: 1
We must do 2 steps to work the long press event:

1. set item's long click listener:



2. in our Adapter's overided function "getView", we shuold set every item be LongClickable.


 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: GestureListener on gridview
 
It's not a secret anymore!