Home
last modified time | relevance | path

Searched refs:MenuItem (Results 1 – 25 of 362) sorted by relevance

12345678910>>...15

/packages/apps/DocumentsUI/src/com/android/documentsui/
DMenuManager.java22 import android.view.MenuItem;
140 MenuItem share = menu.findItem(R.id.dir_menu_share); in updateContextMenuForFiles()
141 MenuItem open = menu.findItem(R.id.dir_menu_open); in updateContextMenuForFiles()
142 MenuItem openWith = menu.findItem(R.id.dir_menu_open_with); in updateContextMenuForFiles()
143 MenuItem rename = menu.findItem(R.id.dir_menu_rename); in updateContextMenuForFiles()
144 MenuItem viewInOwner = menu.findItem(R.id.dir_menu_view_in_owner); in updateContextMenuForFiles()
169 MenuItem openInNewWindow = menu.findItem(R.id.dir_menu_open_in_new_window); in updateContextMenuForDirs()
170 MenuItem rename = menu.findItem(R.id.dir_menu_rename); in updateContextMenuForDirs()
171 MenuItem pasteInto = menu.findItem(R.id.dir_menu_paste_into_folder); in updateContextMenuForDirs()
189 MenuItem cut = menu.findItem(R.id.dir_menu_cut_to_clipboard); in updateContextMenu()
[all …]
/packages/apps/Gallery/src/com/android/camera/
DMenuHelper.java41 import android.view.MenuItem;
107 public void aboutToCall(MenuItem item, IImage image); in aboutToCall()
167 MenuItem item = menu.findItem(MENU_IMAGE_SHARE); in enableShareMenuItem()
182 MenuItem item = menu.findItem(MENU_IMAGE_SHOWMAP); in enableShowOnMapMenuItem()
584 final ArrayList<MenuItem> requiresWriteAccessItems = in addImageMenuItems()
585 new ArrayList<MenuItem>(); in addImageMenuItems()
586 final ArrayList<MenuItem> requiresNoDrmAccessItems = in addImageMenuItems()
587 new ArrayList<MenuItem>(); in addImageMenuItems()
588 final ArrayList<MenuItem> requiresImageItems = in addImageMenuItems()
589 new ArrayList<MenuItem>(); in addImageMenuItems()
[all …]
/packages/apps/DocumentsUI/src/com/android/documentsui/files/
DMenuManager.java27 import android.view.MenuItem;
135 protected void updateSettings(MenuItem settings, RootInfo root) { in updateSettings()
141 protected void updateEject(MenuItem eject, RootInfo root) { in updateEject()
147 protected void updateSettings(MenuItem settings) { in updateSettings()
154 protected void updateNewWindow(MenuItem newWindow) { in updateNewWindow()
159 protected void updateOpenWith(MenuItem openWith, SelectionDetails selectionDetails) { in updateOpenWith()
166 MenuItem openInNewWindow, SelectionDetails selectionDetails) { in updateOpenInNewWindow()
173 protected void updateOpenInNewWindow(MenuItem openInNewWindow, RootInfo root) { in updateOpenInNewWindow()
178 protected void updateMoveTo(MenuItem moveTo, SelectionDetails selectionDetails) { in updateMoveTo()
184 protected void updateCopyTo(MenuItem copyTo, SelectionDetails selectionDetails) { in updateCopyTo()
[all …]
/packages/apps/Car/libs/car-ui-lib/src/com/android/car/ui/toolbar/
DToolbarControllerImpl.java88 private final MenuItem mOverflowButton;
96 private List<MenuItem> mMenuItems = Collections.emptyList();
97 private List<MenuItem> mOverflowItems = new ArrayList<>();
106 private MenuItem.Listener mOverflowItemListener = () -> {
121 mOverflowButton = MenuItem.builder(getContext()) in ToolbarControllerImpl()
370 private void setMenuItemsInternal(@Nullable List<MenuItem> items) { in setMenuItemsInternal()
375 List<MenuItem> visibleMenuItems = new ArrayList<>(); in setMenuItemsInternal()
376 List<MenuItem> overflowItems = new ArrayList<>(); in setMenuItemsInternal()
384 for (MenuItem item : items) { in setMenuItemsInternal()
385 if (item.getDisplayBehavior() == MenuItem.DisplayBehavior.NEVER) { in setMenuItemsInternal()
[all …]
DMenuItemRenderer.java52 class MenuItemRenderer implements MenuItem.Listener {
60 private final MenuItem mMenuItem;
69 MenuItemRenderer(MenuItem item, ViewGroup parentView) { in MenuItemRenderer()
189 static List<MenuItem> readMenuItemList(Context c, @XmlRes int resId) { in readMenuItemList()
196 List<MenuItem> menuItems = new ArrayList<>(); in readMenuItemList()
211 private static MenuItem readMenuItem(Context c, XmlResourceParser parser, AttributeSet attrs) in readMenuItem()
236 MenuItem.OnClickListener onClickListener = null; in readMenuItem()
245 Method m = activity.getClass().getMethod(onClickMethod, MenuItem.class); in readMenuItem()
259 MenuItem.DisplayBehavior displayBehavior = displayBehaviorInt == 0 in readMenuItem()
260 ? MenuItem.DisplayBehavior.ALWAYS in readMenuItem()
[all …]
DMenuItem.java49 public class MenuItem { class
75 private MenuItem(Builder builder) { in MenuItem() method in MenuItem
342 public MenuItem build() { in build()
376 return new MenuItem(this); in build()
559 public static MenuItem createSearch(Context c, OnClickListener listener) { in createSearch()
560 return MenuItem.builder(c) in createSearch()
568 public static MenuItem createSettings(Context c, OnClickListener listener) { in createSettings()
569 return MenuItem.builder(c) in createSettings()
586 void onClick(MenuItem item); in onClick()
DToolbarController.java149 void setMenuItems(@Nullable List<MenuItem> items); in setMenuItems()
180 List<MenuItem> setMenuItems(@XmlRes int resId); in setMenuItems()
184 List<MenuItem> getMenuItems(); in getMenuItems()
188 MenuItem findMenuItemById(int id); in findMenuItemById()
192 MenuItem requireMenuItemById(int id); in requireMenuItemById()
/packages/apps/Car/libs/car-ui-lib/tests/paintbooth/src/com/android/car/ui/paintbooth/toolbar/
DToolbarActivity.java40 import com.android.car.ui.toolbar.MenuItem;
52 private List<MenuItem> mMenuItems = new ArrayList<>();
74 mMenuItems.add(MenuItem.builder(this) in onCreate()
100 mMenuItems.add(MenuItem.builder(this) in onCreate()
109 mMenuItems.add(MenuItem.builder(this) in onCreate()
121 mMenuItems.add(MenuItem.builder(this) in onCreate()
126 .setDisplayBehavior(MenuItem.DisplayBehavior.NEVER) in onCreate()
133 mMenuItems.add(MenuItem.builder(this) in onCreate()
146 mMenuItems.add(MenuItem.builder(this) in onCreate()
156 mMenuItems.add(MenuItem.builder(this) in onCreate()
[all …]
/packages/apps/CellBroadcastReceiver/tests/unit/src/com/android/cellbroadcastreceiver/unit/
DCellBroadcastListActivityTest.java57 import android.view.MenuItem;
213 MenuItem mockMenuItem = mock(MenuItem.class); in testOnContextItemSelectedDelete()
244 MenuItem mockMenuItem = mock(MenuItem.class); in testOnContextItemSelectedViewDetails()
293 MenuItem mockMenuItem = mock(MenuItem.class); in testOnOptionsItemSelected()
305 MenuItem mockMenuItem = mock(MenuItem.class); in testFragmentOnOptionsItemSelected()
338 MenuItem mockMenuItem = mock(MenuItem.class); in testFragmentOnCreateOptionsMenu()
351 MenuItem mockMenuItem = mock(MenuItem.class); in testFragmentOnPrepareOptionsMenu()
/packages/apps/Gallery2/src/com/android/gallery3d/filtershow/history/
DHistoryManager.java20 import android.view.MenuItem;
29 private MenuItem mUndoMenuItem = null;
30 private MenuItem mRedoMenuItem = null;
31 private MenuItem mResetMenuItem = null;
33 public void setMenuItems(MenuItem undoItem, MenuItem redoItem, MenuItem resetItem) { in setMenuItems()
96 private void setEnabled(MenuItem item, boolean enabled) { in setEnabled()
/packages/apps/Car/Media/src/com/android/car/media/widgets/
DAppBarView.java11 import com.android.car.ui.toolbar.MenuItem;
34 private MenuItem mSearch;
35 private MenuItem mSettings;
36 private MenuItem mEqualizer;
37 private MenuItem mAppSelector;
137 mSearch = MenuItem.Builder.createSearch(context, v -> mListener.onSearchSelection()); in init()
138 mSettings = new MenuItem.Builder(context) in init()
143 mEqualizer = new MenuItem.Builder(context) in init()
148 mAppSelector = new MenuItem.Builder(context) in init()
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/latin/userdictionary/
DUserDictionaryAddWordFragment.java29 import android.view.MenuItem;
93 final MenuItem actionItemAdd = menu.add(0, OPTIONS_MENU_ADD, 0, in onCreateOptionsMenu()
96 MenuItem.SHOW_AS_ACTION_IF_ROOM | MenuItem.SHOW_AS_ACTION_WITH_TEXT); in onCreateOptionsMenu()
97 final MenuItem actionItemDelete = menu.add(0, OPTIONS_MENU_DELETE, 0, in onCreateOptionsMenu()
100 MenuItem.SHOW_AS_ACTION_IF_ROOM | MenuItem.SHOW_AS_ACTION_WITH_TEXT); in onCreateOptionsMenu()
110 public boolean onOptionsItemSelected(MenuItem item) { in onOptionsItemSelected()
/packages/apps/Gallery2/src/com/android/photos/
DMultiChoiceManager.java29 import android.view.MenuItem;
134 MenuItem editItem = menu.findItem(R.id.menu_edit); in updateActionItemVisibilities()
135 MenuItem deleteItem = menu.findItem(R.id.menu_delete); in updateActionItemVisibilities()
136 MenuItem shareItem = menu.findItem(R.id.menu_share); in updateActionItemVisibilities()
137 MenuItem cropItem = menu.findItem(R.id.menu_crop); in updateActionItemVisibilities()
138 MenuItem trimItem = menu.findItem(R.id.menu_trim); in updateActionItemVisibilities()
139 MenuItem muteItem = menu.findItem(R.id.menu_mute); in updateActionItemVisibilities()
140 MenuItem setAsItem = menu.findItem(R.id.menu_set_as); in updateActionItemVisibilities()
157 MenuItem menuItem = menu.findItem(R.id.menu_share); in onCreateActionMode()
207 public boolean onActionItemClicked(ActionMode mode, MenuItem item) { in onActionItemClicked()
/packages/apps/Car/libs/car-ui-lib/tests/robotests/src/com/android/car/ui/toolbar/
DToolbarTest.java306 MenuItem item = MenuItem.builder(mContext) in menuItems_builder_id()
315 MenuItem item = MenuItem.builder(mContext).build(); in menuItems_setId_shouldWork()
362 MenuItem item = createMenuItem(i -> { in menuItems_setVisibility_shouldDefaultToShown()
371 MenuItem item = createMenuItem(i -> { in menuItems_setVisibility_shouldHide()
381 MenuItem item = createMenuItem(i -> { in menuItems_setVisibility_shouldReshowAfterHiding()
392 List<MenuItem> menuItems = Arrays.asList( in menuItems_equalItems_shouldntRecreateViews()
411 MenuItem.builder(mContext).setToSearch().build(), in menuItems_searchScreen_shouldHideMenuItems()
425 MenuItem.builder(mContext).setToSearch().build(), in menuItems_showMenuItemsWhileSearching()
438 private MenuItem createMenuItem(MenuItem.OnClickListener listener) { in createMenuItem()
439 return MenuItem.builder(mContext) in createMenuItem()
/packages/apps/Messaging/src/com/android/messaging/ui/conversationlist/
DMultiSelectActionModeCallback.java23 import android.view.MenuItem;
71 private MenuItem mArchiveMenuItem;
72 private MenuItem mUnarchiveMenuItem;
73 private MenuItem mAddContactMenuItem;
74 private MenuItem mBlockMenuItem;
75 private MenuItem mNotificationOnMenuItem;
76 private MenuItem mNotificationOffMenuItem;
105 public boolean onActionItemClicked(ActionMode actionMode, MenuItem menuItem) { in onActionItemClicked()
/packages/apps/Settings/src/com/android/settings/print/
DPrintJobSettingsFragment.java25 import android.view.MenuItem;
78 MenuItem cancel = menu.add(0, MENU_ITEM_ID_CANCEL, Menu.NONE, in onCreateOptionsMenu()
80 cancel.setShowAsAction(MenuItem.SHOW_AS_ACTION_IF_ROOM); in onCreateOptionsMenu()
84 MenuItem restart = menu.add(0, MENU_ITEM_ID_RESTART, Menu.NONE, in onCreateOptionsMenu()
86 restart.setShowAsAction(MenuItem.SHOW_AS_ACTION_IF_ROOM); in onCreateOptionsMenu()
91 public boolean onOptionsItemSelected(MenuItem item) { in onOptionsItemSelected()
/packages/services/Car/tests/CarDeveloperOptions/src/com/android/car/developeroptions/print/
DPrintJobSettingsFragment.java25 import android.view.MenuItem;
78 MenuItem cancel = menu.add(0, MENU_ITEM_ID_CANCEL, Menu.NONE, in onCreateOptionsMenu()
80 cancel.setShowAsAction(MenuItem.SHOW_AS_ACTION_IF_ROOM); in onCreateOptionsMenu()
84 MenuItem restart = menu.add(0, MENU_ITEM_ID_RESTART, Menu.NONE, in onCreateOptionsMenu()
86 restart.setShowAsAction(MenuItem.SHOW_AS_ACTION_IF_ROOM); in onCreateOptionsMenu()
91 public boolean onOptionsItemSelected(MenuItem item) { in onOptionsItemSelected()
/packages/apps/DocumentsUI/src/com/android/documentsui/base/
DMenus.java20 import android.view.MenuItem;
29 public static void disableHiddenItems(Menu menu, MenuItem... exclusions) { in disableHiddenItems()
31 MenuItem item = menu.getItem(i); in disableHiddenItems()
42 private static boolean contains(MenuItem[] exclusions, MenuItem item) { in contains()
/packages/apps/Car/Settings/src/com/android/car/settings/applications/
DApplicationDetailsFragment.java51 import com.android.car.ui.toolbar.MenuItem;
104 private MenuItem mUninstallButton;
105 private MenuItem mForceStopButton;
117 public List<MenuItem> getToolbarMenuItems() { in getToolbarMenuItems()
166 mUninstallButton = new MenuItem.Builder(getContext()).build(); in onCreate()
167 mForceStopButton = new MenuItem.Builder(getContext()) in onCreate()
407 private final MenuItem.OnClickListener mForceStopClickListener = i -> {
437 private final MenuItem.OnClickListener mDisableClickListener = i -> {
448 private final MenuItem.OnClickListener mEnableClickListener = i -> {
453 private final MenuItem.OnClickListener mUninstallClickListener = i -> {
/packages/apps/DocumentsUI/src/com/android/documentsui/picker/
DMenuManager.java30 import android.view.MenuItem;
86 protected void updateModePicker(MenuItem grid, MenuItem list) { in updateModePicker()
97 protected void updateSelectAll(MenuItem selectAll) { in updateSelectAll()
105 protected void updateCreateDir(MenuItem createDir) { in updateCreateDir()
111 protected void updateSelect(MenuItem select, SelectionDetails selectionDetails) { in updateSelect()
/packages/apps/Car/Settings/src/com/android/car/settings/bluetooth/
DBluetoothDeviceDetailsFragment.java28 import com.android.car.ui.toolbar.MenuItem;
48 private MenuItem mConnectionButton;
49 private MenuItem mForgetButton;
63 public List<MenuItem> getToolbarMenuItems() { in getToolbarMenuItems()
71 mConnectionButton = new MenuItem.Builder(getContext()).build(); in onCreate()
73 mForgetButton = new MenuItem.Builder(getContext()) in onCreate()
/packages/apps/Settings/tests/robotests/src/com/android/settings/applications/appinfo/
DInstantAppButtonsPreferenceControllerTest.java41 import android.view.MenuItem;
133 when(menu.add(anyInt(), anyInt(), anyInt(), anyInt())).thenReturn(mock(MenuItem.class)); in onCreateOptionsMenu_noLaunchUri_shouldNotAddInstallInstantAppMenu()
145 when(menu.add(anyInt(), anyInt(), anyInt(), anyInt())).thenReturn(mock(MenuItem.class)); in onCreateOptionsMenu_hasLaunchUri_shouldAddForceStop()
157 final MenuItem menuItem = mock(MenuItem.class); in onPrepareOptionsMenu_noAppStoreLink_shoulDisableInstallInstantAppMenu()
175 final MenuItem menuItem = mock(MenuItem.class); in onPrepareOptionsMenu_hasAppStoreLink_shoulNotDisableInstallInstantAppMenu()
203 final MenuItem menu = mock(MenuItem.class); in onOptionsItemSelected_shouldOpenAppStore()
/packages/apps/Car/Settings/src/com/android/car/settings/users/
DEditUsernameFragment.java35 import com.android.car.ui.toolbar.MenuItem;
47 private MenuItem mOkButton;
48 private MenuItem mCancelButton;
64 public List<MenuItem> getToolbarMenuItems() { in getToolbarMenuItems()
85 mCancelButton = new MenuItem.Builder(getContext()) in onCreate()
89 mOkButton = new MenuItem.Builder(getContext()) in onCreate()
/packages/apps/DocumentsUI/tests/common/com/android/documentsui/testing/
DTestMenuItem.java23 import android.view.MenuItem;
37 public abstract class TestMenuItem implements MenuItem {
67 public MenuItem setEnabled(boolean enabled) { in setEnabled()
73 public MenuItem setVisible(boolean visible) { in setVisible()
89 final public MenuItem setActionView(View actionView) { in setActionView()
/packages/apps/Settings/tests/robotests/src/com/android/settings/applications/manageapplications/
DManageApplicationsTest.java50 import android.view.MenuItem;
93 private MenuItem mAppReset;
94 private MenuItem mSortRecent;
95 private MenuItem mSortFrequent;
167 final MenuItem searchMenu = mock(MenuItem.class); in onCreateOptionsMenu_shouldSetSearchQueryListener()
168 final MenuItem helpMenu = mock(MenuItem.class); in onCreateOptionsMenu_shouldSetSearchQueryListener()
184 final MenuItem searchMenu = mock(MenuItem.class); in onCreateOptionsMenu_hasExpandSearchFlag_shouldExpandSearchView()
185 final MenuItem helpMenu = mock(MenuItem.class); in onCreateOptionsMenu_hasExpandSearchFlag_shouldExpandSearchView()

12345678910>>...15