Andrew wrote:
> How to implement a pop up menu? Example for pressing and holding the
> listview.

You are looking for context menus. To implement context menus in the 0.9 
SDK, you need to:

1. Call Activity#registerForContextMenu(View) somewhere (e.g., in 
onCreate()) to indicate which widget(s) get a context menu

2. Implement onCreateContextMenu() in your activity to supply the menu 
when the user long-taps on your widget

The following tutorials ship with the SDK (in samples/) that demonstrate 
this:

./ApiDemos/src/com/android/samples/view/Gallery1.java
./ApiDemos/src/com/android/samples/view/ExpandableList1.java

If that didn't help, write back with more details!

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com
_The Busy Coder's Guide to Android Development_ Version 1.1 Published!

--~--~---------~--~----~------------~-------~--~----~
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
[EMAIL PROTECTED]
Announcing the new Android 0.9 SDK beta!
http://android-developers.blogspot.com/2008/08/announcing-beta-release-of-android-sdk.html
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to