Hi,

Maybe this can help:

    @Override
    public void onCreateContextMenu(ContextMenu menu, View view,
ContextMenuInfo menuInfo) {
        AdapterView.AdapterContextMenuInfo info;
        try {
             info = (AdapterView.AdapterContextMenuInfo) menuInfo;
        } catch (ClassCastException e) {
            Log.e(TAG, "bad menuInfo", e);
            return;
        }

        long l = getListAdapter().getItemId(info.position);
    }



On Dec 1 2008, 7:12 pm, Thao <thao.uye...@gmail.com> wrote:
> Hi all,
>
> I have an Activity that implements a ListActivty. In there, I have a
> list of item that is wrapped by a custom adapter.
>
> I would like to enable long click on each item in my list, but I can't
> figure out how to do this...Could someone give an example please ?
>
> Thank.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to