开发者

Multiple menu creation in one application possible?

开发者 https://www.devze.com 2023-03-31 05:40 出处:网络
I\'m trying to create a multip开发者_Python百科le menu create in one application. Is this possible or not? Thanks in Advance.You can create one menu inside an Activity. However, you can changing the m

I'm trying to create a multip开发者_Python百科le menu create in one application. Is this possible or not? Thanks in Advance.


You can create one menu inside an Activity. However, you can changing the menu items at runtime, depending on the current state of the activity. To achieve this you should override the onPrepareOptionsMenu() method. This method is called every time the user opens the menu, so you can recreate the menu every time it becomes visible. Hope this helps.

0

精彩评论

暂无评论...
验证码 换一张
取 消