I've a Video View displayed on the UI. The Video View seems to be
working fine. But, I want to use Context Menu on that. For ex: I would
like to pause it if the user makes a long press. I registered the
ContextMenu in the activity onCreate as follows:

onCreate (...)
{
...
this.myVideo = (VideoView) findViewById(R.id.video);
registerForContextMenu(this.myVideo);

...
}

When code is executed no error is logged. However, the
onCreateContextMenu is not getting called.

 public void onCreateContextMenu(ContextMenu menu, View v,
                ContextMenuInfo menuInfo) {
        menu.add(0, PAUSE_PLAY, 0, "Pause play");


Neither on long press the menu does not show up.

Is Context Menu is supported only for ListView?

thanks for your responses!

-- 
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