org.androidannotations.annotations
Annotation Type ItemLongClick
@Retention(value=CLASS)
@Target(value=METHOD)
public @interface ItemLongClick
This annotation is intended to be used on methods to receive events defined
by android.widget.AdapterView.OnItemLongClickListener#onItemLongClick(android.
widget. AdapterView>, android.view.View, int, long)
when a list item has
been long clicked by the user.
The annotation value should be one or several of R.id.* fields. If not set,
the method name will be used as the R.id.* field name.
The method MAY have one parameter :
- An
int
parameter to know the position of the clicked item.
Or, a parameter of the type of the Adapter linked to the listview.
Example :
@ItemLongClick(R.id.myList)
public void itemLongClickedOnMyList() {
// ...
}
@ItemLongClick(R.id.myList)
public void myListItemPositionLongClicked(int position) {
// ...
}
@ItemLongClick
public void myListItemLongClicked(MyItem clickedItem) {
// ...
}
- See Also:
ItemClick
,
ItemSelect
value
public abstract int[] value
- Default:
- -1
resName
public abstract String[] resName
- Default:
- ""
Copyright © 2010-2014. All Rights Reserved.