Persisting a context menu after screen rotation

Posted by Macarse on Stack Overflow See other posts from Stack Overflow or by Macarse
Published on 2009-11-02T23:58:43Z Indexed on 2010/06/01 23:53 UTC
Read the original article Hit count: 187

Filed under:
|

Hi.

I have an activity that on it's onCreate method it does:

registerForContextMenu(theView);

and in onCreateContextMenu:

super.onCreateContextMenu(menu, v, menuInfo);
menu.add(blablabla);

This works great, but the problem is that the context menu disappears when the screen rotates. How to fix this?

Thanks for reading!

© Stack Overflow or respective owner

Related posts about android

Related posts about contextmenu