http://code.google.com/intl/es-AR/andro ... omXml.html
In particular I don't understand how this method works :
Using java Syntax Highlighting
- @Override
- public boolean onCreateOptionsMenu(Menu menu) {
- // Hold on to this
- mMenu = menu;
- // Inflate the currently selected menu XML resource.
- MenuInflater inflater = getMenuInflater();
- inflater.inflate(sMenuExampleResources[mSpinner.getSelectedItemPosition()], menu);
- // Disable the spinner since we've already created the menu and the user
- // can no longer pick a different menu XML.
- mSpinner.setEnabled(false);
- // Change instructions
- mInstructionsText.setText(getResources().getString(
- R.string.menu_from_xml_instructions_go_back));
- return true;
- }
Parsed in 0.031 seconds, using GeSHi 1.0.8.4
How should be the XML file so that this code work, or to create a group menu? I will be very grateful if some one could help me. Thanks in advance!
Regards,
Helios


