Android Development - getMenuInflater(R.menu.main, menu)

前端 未结 6 893
心在旅途
心在旅途 2021-01-03 05:02

I\'m learning android and following a simple camera app tutorial. There\'s a snippet of code that I\'ve reproduced but I am getting an error on it and I\'m not sure why.

6条回答
  •  没有蜡笔的小新
    2021-01-03 05:46

    on your res/ directory right click, and choose new >> android resource file . and then name your menu as you like but make resource type is menu and android studio will create it for you and then in the file you should find this

    
    

    and then add your items as you like

    
    
    

提交回复
热议问题