Searched refs:menu (Results 1 - 25 of 117) sorted by relevance

12345

/frameworks/base/core/tests/coretests/src/android/view/menu/
H A DMenuLayoutLandscape.java17 package android.view.menu;
H A DMenuLayoutPortrait.java17 package android.view.menu;
H A DMenuLayout.java17 package android.view.menu;
19 import android.view.menu.MenuScenario.Params;
41 public boolean onPrepareOptionsMenu(Menu menu) { argument
44 * This activity is meant to try a bunch of different menu layouts. So,
45 * we recreate the menu every time it is prepared.
47 menu.clear();
48 onCreateOptionsMenu(menu);
H A DMenuWith1ItemTest.java17 package android.view.menu;
19 import android.view.menu.MenuWith1Item;
21 import com.android.internal.view.menu.MenuBuilder;
53 // Open menu, click on an item
67 // open menu, move around to give it focus
72 // close the menu
81 // open the menu, menu item shouldn't be focused, because we are not
H A DMenuScenario.java17 package android.view.menu;
28 * number of menu items. Used @link {@link ListScenario} as a reference.
59 public boolean onCreateOptionsMenu(Menu menu) { argument
61 mMenu = menu;
67 if ((item = onAddMenuItem(menu, i)) == null) {
71 item = menu.add(0, 0, 0, (givenTitle != null) ? givenTitle : ("Item " + i));
88 public boolean onPrepareOptionsMenu(Menu menu) { argument
90 mMenu = menu;
96 * Override this to add an item to the menu.
100 * @return The item that was added to the menu, o
103 onAddMenuItem(Menu menu, int itemPosition) argument
[all...]
/frameworks/base/core/tests/coretests/src/android/view/
H A DListContextMenu.java98 public boolean onCreateOptionsMenu(Menu menu) { argument
99 MenuItem item = menu.add(0, 0, 0, "Really long menu item name");
103 SubMenu sm = menu.addSubMenu(0, 0, 0, "The 2nd item, a sub menu").setIcon(R.drawable.black_square_stretchable);
105 item.setTitleCondensed("Sub menu");
110 menu.add(0, 0, 0, "Item 3");
111 menu.add(0, 0, 0, "Item 4");
112 menu.add(0, 0, 0, "Item 5");
113 menu
130 onCreateContextMenu(ContextMenu menu, View v, ContextMenuInfo menuInfo) argument
184 onOptionsMenuClosed(Menu menu) argument
196 onContextMenuClosed(Menu menu) argument
[all...]
/frameworks/base/core/java/com/android/internal/view/menu/
H A DMenuPresenter.java17 package com.android.internal.view.menu;
30 * Called by menu implementation to notify another component of open/close events.
34 * Called when a menu is closing.
35 * @param menu
38 public void onCloseMenu(MenuBuilder menu, boolean allMenusAreClosing); argument
42 * of menu state so that it does not attempt to hide the action bar
53 * Initialize this presenter for the given context and menu.
58 * @param menu Menu to host
60 public void initForMenu(Context context, MenuBuilder menu); argument
63 * Retrieve a MenuView to display the menu specifie
104 onCloseMenu(MenuBuilder menu, boolean allMenusAreClosing) argument
119 expandItemActionView(MenuBuilder menu, MenuItemImpl item) argument
128 collapseItemActionView(MenuBuilder menu, MenuItemImpl item) argument
[all...]
H A DMenuView.java17 package com.android.internal.view.menu;
19 import com.android.internal.view.menu.MenuBuilder;
20 import com.android.internal.view.menu.MenuItemImpl;
25 * Minimal interface for a menu view. {@link #initialize(MenuBuilder)} must be called for the
26 * menu to be functional.
32 * Initializes the menu to the given menu. This should be called after the
35 * @param menu The menu that this MenuView should display.
37 public void initialize(MenuBuilder menu); argument
[all...]
H A DMenuDialogHelper.java17 package com.android.internal.view.menu;
42 public MenuDialogHelper(MenuBuilder menu) { argument
43 mMenu = menu;
47 * Shows menu as a dialog.
53 final MenuBuilder menu = mMenu;
56 final AlertDialog.Builder builder = new AlertDialog.Builder(menu.getContext());
66 final View headerView = menu.getHeaderView();
72 builder.setIcon(menu.getHeaderIcon()).setTitle(menu.getHeaderTitle());
78 // Show the menu
149 onCloseMenu(MenuBuilder menu, boolean allMenusAreClosing) argument
[all...]
H A DExpandedMenuView.java17 package com.android.internal.view.menu;
20 import com.android.internal.view.menu.MenuBuilder.ItemInvoker;
31 * The expanded menu view is a list-like menu with all of the available menu items. It is opened
32 * by the user clicking no the 'More' button on the icon menu view.
37 /** Default animations for this menu */
42 * @param menu The model for the menu which this MenuView will display
54 public void initialize(MenuBuilder menu) { argument
[all...]
H A DBaseMenuPresenter.java17 package com.android.internal.view.menu;
50 * @param menuLayoutRes Layout resource ID for the menu container view
61 public void initForMenu(Context context, MenuBuilder menu) { argument
64 mMenu = menu;
165 * @return View that presents the requested menu item
191 * @return true if this item should be included in this menu presentation; false otherwise
197 public void onCloseMenu(MenuBuilder menu, boolean allMenusAreClosing) { argument
199 mCallback.onCloseMenu(menu, allMenusAreClosing);
203 public boolean onSubMenuSelected(SubMenuBuilder menu) { argument
205 return mCallback.onOpenSubMenu(menu);
214 expandItemActionView(MenuBuilder menu, MenuItemImpl item) argument
218 collapseItemActionView(MenuBuilder menu, MenuItemImpl item) argument
[all...]
/frameworks/support/v7/appcompat/src/android/support/v7/internal/view/menu/
H A DMenuPresenter.java17 package android.support.v7.internal.view.menu;
32 * Called by menu implementation to notify another component of open/close events.
39 * Called when a menu is closing.
41 public void onCloseMenu(MenuBuilder menu, boolean allMenusAreClosing); argument
44 * Called when a submenu opens. Useful for notifying the application of menu state so that
55 * Initialize this presenter for the given context and menu. This method is called by
60 * @param menu Menu to host
62 public void initForMenu(Context context, MenuBuilder menu); argument
65 * Retrieve a MenuView to display the menu specified in
74 * Update the menu U
106 onCloseMenu(MenuBuilder menu, boolean allMenusAreClosing) argument
122 expandItemActionView(MenuBuilder menu, MenuItemImpl item) argument
131 collapseItemActionView(MenuBuilder menu, MenuItemImpl item) argument
[all...]
H A DMenuView.java17 package android.support.v7.internal.view.menu;
22 * Minimal interface for a menu view. {@link #initialize(MenuBuilder)} must be called for the menu
30 * Initializes the menu to the given menu. This should be called after the view is inflated.
32 * @param menu The menu that this MenuView should display.
34 public void initialize(MenuBuilder menu); argument
37 * Returns the default animations to be used for this menu when entering/exiting.
39 * @return A resource ID for the default animations to be used for this menu
[all...]
H A DExpandedMenuView.java17 package android.support.v7.internal.view.menu;
20 import android.support.v7.internal.view.menu.MenuBuilder;
21 import android.support.v7.internal.view.menu.MenuBuilder.ItemInvoker;
22 import android.support.v7.internal.view.menu.MenuView;
30 * The expanded menu view is a list-like menu with all of the available menu items. It is opened
31 * by the user clicking no the 'More' button on the icon menu view.
39 /** Default animations for this menu */
48 public void initialize(MenuBuilder menu) { argument
[all...]
H A DMenuDialogHelper.java17 package android.support.v7.internal.view.menu;
43 public MenuDialogHelper(MenuBuilder menu) { argument
44 mMenu = menu;
48 * Shows menu as a dialog.
54 final MenuBuilder menu = mMenu;
57 final AlertDialog.Builder builder = new AlertDialog.Builder(menu.getContext());
69 final View headerView = menu.getHeaderView();
75 builder.setIcon(menu.getHeaderIcon()).setTitle(menu.getHeaderTitle());
81 // Show the menu
152 onCloseMenu(MenuBuilder menu, boolean allMenusAreClosing) argument
[all...]
H A DBaseWrapper.java17 package android.support.v7.internal.view.menu;
H A DBaseMenuPresenter.java17 package android.support.v7.internal.view.menu;
53 * @param menuLayoutRes Layout resource ID for the menu container view
64 public void initForMenu(Context context, MenuBuilder menu) { argument
67 mMenu = menu;
171 * @return View that presents the requested menu item
197 * @return true if this item should be included in this menu presentation; false otherwise
203 public void onCloseMenu(MenuBuilder menu, boolean allMenusAreClosing) { argument
205 mCallback.onCloseMenu(menu, allMenusAreClosing);
209 public boolean onSubMenuSelected(SubMenuBuilder menu) { argument
211 return mCallback.onOpenSubMenu(menu);
220 expandItemActionView(MenuBuilder menu, MenuItemImpl item) argument
224 collapseItemActionView(MenuBuilder menu, MenuItemImpl item) argument
[all...]
/frameworks/support/v7/appcompat/src/android/support/v7/widget/
H A DPopupMenu.java21 import android.support.v7.internal.view.menu.MenuBuilder;
22 import android.support.v7.internal.view.menu.MenuPopupHelper;
23 import android.support.v7.internal.view.menu.MenuPresenter;
24 import android.support.v7.internal.view.menu.SubMenuBuilder;
46 * Callback interface used to notify the application that the menu has closed.
50 * Called when the associated menu has been dismissed.
52 * @param menu The PopupMenu that was dismissed.
54 public void onDismiss(PopupMenu menu); argument
85 * @return a {@link MenuInflater} that can be used to inflate menu items from XML into the
86 * menu returne
140 onMenuItemSelected(MenuBuilder menu, MenuItem item) argument
150 onCloseMenu(MenuBuilder menu, boolean allMenusAreClosing) argument
174 onCloseSubMenu(SubMenuBuilder menu) argument
180 onMenuModeChange(MenuBuilder menu) argument
[all...]
/frameworks/base/core/java/android/widget/
H A DPopupMenu.java19 import com.android.internal.view.menu.MenuBuilder;
20 import com.android.internal.view.menu.MenuPopupHelper;
21 import com.android.internal.view.menu.MenuPresenter;
22 import com.android.internal.view.menu.SubMenuBuilder;
49 * Callback interface used to notify the application that the menu has closed.
53 * Called when the associated menu has been dismissed.
55 * @param menu The PopupMenu that was dismissed.
57 public void onDismiss(PopupMenu menu); argument
144 * @return a {@link MenuInflater} that can be used to inflate menu items from XML into the
145 * menu returne
199 onMenuItemSelected(MenuBuilder menu, MenuItem item) argument
209 onCloseMenu(MenuBuilder menu, boolean allMenusAreClosing) argument
233 onCloseSubMenu(SubMenuBuilder menu) argument
239 onMenuModeChange(MenuBuilder menu) argument
[all...]
/frameworks/base/tests/HwAccelerationTest/src/com/android/test/hwui/
H A DListActivity.java98 public void onCreateContextMenu(ContextMenu menu, View v, ContextMenu.ContextMenuInfo menuInfo) { argument
99 super.onCreateContextMenu(menu, v, menuInfo);
100 menu.setHeaderTitle("Context menu");
101 menu.add("List item 1");
102 menu.add("List item 2");
103 menu.add("List item 3");
H A DTransparentListActivity.java96 public void onCreateContextMenu(ContextMenu menu, View v, ContextMenu.ContextMenuInfo menuInfo) { argument
97 super.onCreateContextMenu(menu, v, menuInfo);
98 menu.setHeaderTitle("Context menu");
99 menu.add("List item 1");
100 menu.add("List item 2");
101 menu.add("List item 3");
/frameworks/opt/mailcommon/java/com/android/mailcommon/
H A DWebViewContextMenu.java45 * <p>Handles display and behavior of the context menu for known actionable content in WebViews.
52 * <li>res/menu/webview_context_menu.xml</li>
86 // For our copy menu items.
101 // For our share menu items.
143 public void onCreateContextMenu(ContextMenu menu, View v, argument
164 // an inflated menu can be used again. This is not available
167 // Also, we are copying the menu file from browser until
169 inflater.inflate(getMenuResourceId(), menu);
171 // Initially make set the menu item handler this WebViewContextMenu, which will default to
173 for (int i = 0; i < menu
[all...]
/frameworks/support/v7/appcompat/src/android/support/v7/app/
H A DActionBarActivityDelegateBase.java26 import android.support.v7.internal.view.menu.ListMenuPresenter;
27 import android.support.v7.internal.view.menu.MenuBuilder;
28 import android.support.v7.internal.view.menu.MenuPresenter;
29 import android.support.v7.internal.view.menu.MenuView;
30 import android.support.v7.internal.view.menu.MenuWrapperFactory;
69 final MenuBuilder menu = createMenu();
70 if (mActivity.superOnCreatePanelMenu(Window.FEATURE_OPTIONS_PANEL, menu) &&
71 mActivity.superOnPreparePanel(Window.FEATURE_OPTIONS_PANEL, null, menu)) {
72 setMenu(menu);
279 MenuBuilder menu
319 onCreatePanelMenu(int featureId, Menu menu) argument
327 onPreparePanel(int featureId, View view, Menu menu) argument
343 onMenuItemSelected(MenuBuilder menu, MenuItem item) argument
348 onMenuModeChange(MenuBuilder menu) argument
353 onCloseMenu(MenuBuilder menu, boolean allMenusAreClosing) argument
399 reopenMenu(MenuBuilder menu, boolean toggleMenuMode) argument
438 setMenu(MenuBuilder menu) argument
591 onCreateActionMode(ActionMode mode, Menu menu) argument
595 onPrepareActionMode(ActionMode mode, Menu menu) argument
[all...]
/frameworks/base/core/java/com/android/internal/view/
H A DStandaloneActionMode.java18 import com.android.internal.view.menu.MenuBuilder;
19 import com.android.internal.view.menu.MenuPopupHelper;
20 import com.android.internal.view.menu.SubMenuBuilder;
132 public boolean onMenuItemSelected(MenuBuilder menu, MenuItem item) { argument
136 public void onCloseMenu(MenuBuilder menu, boolean allMenusAreClosing) { argument
148 public void onCloseSubMenu(SubMenuBuilder menu) { argument
151 public void onMenuModeChange(MenuBuilder menu) { argument
/frameworks/base/core/java/android/view/
H A DActionMode.java27 * read the <a href="{@docRoot}guide/topics/ui/menus.html#context-menu">Menus</a>
157 * Invalidate the action mode and refresh menu content. The mode's
160 * If it returns true the menu will be scanned for updated content and any relevant changes
172 * Returns the menu of actions that this action mode presents.
173 * @return The action mode's menu.
231 * Called when action mode is first created. The menu supplied will be used to
235 * @param menu Menu used to populate action buttons
239 public boolean onCreateActionMode(ActionMode mode, Menu menu); argument
242 * Called to refresh an action mode's action menu whenever it is invalidated.
245 * @param menu Men
248 onPrepareActionMode(ActionMode mode, Menu menu) argument
[all...]

Completed in 319 milliseconds

12345