Home | History | Annotate | Download | only in skeletonapp

Lines Matching refs:Menu

22 import android.view.Menu;
36 static final private int BACK_ID = Menu.FIRST;
37 static final private int CLEAR_ID = Menu.FIRST + 1;
72 * Called when your activity's options menu needs to be created.
75 public boolean onCreateOptionsMenu(Menu menu) {
76 super.onCreateOptionsMenu(menu);
81 menu.add(0, BACK_ID, 0, R.string.back).setShortcut('0', 'b');
82 menu.add(0, CLEAR_ID, 0, R.string.clear).setShortcut('1', 'c');
88 * Called right before your activity's option menu is displayed.
91 public boolean onPrepareOptionsMenu(Menu menu) {
92 super.onPrepareOptionsMenu(menu);
94 // Before showing the menu, we need to decide whether the clear
96 menu.findItem(CLEAR_ID).setVisible(mEditor.getText().length() > 0);
102 * Called when a menu item is selected.