I'm working on a project where I need to replace the ABS with an customview. I have a button on the top right corner. When you click that button I want a Spinner/contextMenu/overflow menu shown (like the standard abs with overflow theme).
The button will trigger the onCreateOptionsMenu(Menu menu) to be called
Untill now I only managed to get the menu on the bottom of the activity (contextmenu) with following code:
@Override
public boolean onCreateOptionsMenu(final Menu menu){
menu.add(Menu.None, "", Menu.None, "title").setShowAsAction (MenuItem.SHOW_AS_ACTION_NEVER);
menu.add(Menu.None, "", Menu.None, "title").setShowAsAction (MenuItem.SHOW_AS_ACTION_NEVER);
return super.onCreateOptionsMenu(menu)
}
After doing some research I found that PopUpMenuHelper could help me, but if fail to find some samples/examples.
Has someone done something similair? Any tips? Any libraries or classes that I could use?
Any suggestion is appreciated