Menu Item Flashcards

1
Q

Tell me all of the steps to add a menu Item

A
  1. Create a resource XML file
  2. Override onCreateOptionsMenu
  3. Inflate the menu inside it
  4. Override onOptionsItemSelected
  5. Implement what should be happening clicking on that item => to recognize which one is clicked get the item id
  6. Make that activity
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

How do you inlfate a menu ??

A

getMenuInflater().inflate(R.menu.main, menu);

How well did you know this?
1
Not at all
2
3
4
5
Perfectly