I'll be brief. I have a ListActivity that uses a custom Adapter
implementing BaseAdapter.
When I perform a click on an object, the method
ListActivity.onListItemClick() gets executed.
Is there a way to execute a different portion of code when I perform a
LONG click on an item?
Thanks,
Simone
--
When you long click on a list item, the method onItemLongClick should be
called. If you want your own listener, you cannot do that on the stock
listview. Extend and create your own list view and configure a separate
lintener for that.
On Sat, Oct 16, 2010 at 2:39 PM, Simone
Simone,
If the purpose of handling long-clicks is to display a context menu for
list items, you can use this:
yourActivity.registerForContextMenu(yourListViewReference)
If it's actually the long click you want, you can set a listener for it:
3 matches
Mail list logo