Simon Macha Mwas
Simon Macha Mwas

Reputation: 327

Menu that appears from above and below hides and shows on screen touch in android without using the menu button

Is it possible to create a menu in android that shows when someone for example touches a graph and It brings more options. I want a menu that will appear from above and below like how the menu used to be in android when you touch the menu button. Now without the button i would like the user to touch a chart or a table and two menus appear from above and below or even sides. Any suggestions will highly be appreciated

Upvotes: 0

Views: 247

Answers (2)

Manoj Kumar
Manoj Kumar

Reputation: 1520

I think what u need is a context menu; see this example Hope this helps :) cheers :)

Upvotes: 0

Andy Res
Andy Res

Reputation: 16043

Suggestion:
Make the layout of menu you would like to show, and include it in the layout of your activity. By default set it to be GONE, this will hide it.
Then set a touch listener for your graph, and change the visibility of menu to VISIBLE to show it.

Upvotes: 2

Related Questions