Hi i am creating a contextmenu for my view that is whole screen just
like when we longpress on calendar monthview or weekview  i tried in
below three methods


===============================================================
setContentView(demoview);

demoview.setOnCreateContextMenuListener(new
View.OnCreateContextMenuListener() {
public void onCreateContextMenu(ContextMenu menu, View v,
ContextMenu.ContextMenuInfo menuInfo) {
menu.setHeaderTitle("Menu");
menu.add(0, 1, 0, "Add");
menu.add(0, 2, 0, "Delete");
menu.add(0, 3, 0, "Edit");
}
});
===============================================================
and i also tried with this

setContentView(demoview);
 registerForContextMenu(view)


===============================================================
and also

setContentView(demoview);
 registerForContextMenu(view)

in longpress
demoview.performLongClick();

===============================================================
though contextmenu pops up on longpress other events are getting
overrided such as singletap, onfling etc, is there any way to
implement contextmenu so that it gets popped up when clicked on any
part of the screen without loosing other events such as onfling and
showpress etc?

Thanks,

http://www.ceveni.com/

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

Reply via email to