2 * ownCloud Android client application
4 * @author Andy Scherzinger
5 * Copyright (C) 2015 ownCloud Inc.
7 * This program is free software: you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License version 2,
9 * as published by the Free Software Foundation.
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License
17 * along with this program. If not, see <http://www.gnu.org/licenses/>.
21 package com
.owncloud
.android
.utils
;
23 import android
.content
.Intent
;
24 import android
.graphics
.drawable
.Drawable
;
25 import android
.view
.ActionProvider
;
26 import android
.view
.ContextMenu
;
27 import android
.view
.MenuItem
;
28 import android
.view
.SubMenu
;
29 import android
.view
.View
;
32 * Created by scherzia on 17.08.2015.
34 public class DialogMenuItem
implements MenuItem
{
38 public DialogMenuItem(int itemId
) {
39 this.mItemId
= itemId
;
43 public int getItemId() {
48 public int getGroupId() {
53 public int getOrder() {
58 public MenuItem
setTitle(CharSequence title
) {
64 public MenuItem
setTitle(int title
) {
69 public CharSequence
getTitle() {
74 public MenuItem
setTitleCondensed(CharSequence title
) {
79 public CharSequence
getTitleCondensed() {
84 public MenuItem
setIcon(Drawable icon
) {
89 public MenuItem
setIcon(int iconRes
) {
94 public Drawable
getIcon() {
99 public MenuItem
setIntent(Intent intent
) {
104 public Intent
getIntent() {
109 public MenuItem
setShortcut(char numericChar
, char alphaChar
) {
114 public MenuItem
setNumericShortcut(char numericChar
) {
119 public char getNumericShortcut() {
124 public MenuItem
setAlphabeticShortcut(char alphaChar
) {
129 public char getAlphabeticShortcut() {
134 public MenuItem
setCheckable(boolean checkable
) {
139 public boolean isCheckable() {
144 public MenuItem
setChecked(boolean checked
) {
149 public boolean isChecked() {
154 public MenuItem
setVisible(boolean visible
) {
159 public boolean isVisible() {
164 public MenuItem
setEnabled(boolean enabled
) {
169 public boolean isEnabled() {
174 public boolean hasSubMenu() {
179 public SubMenu
getSubMenu() {
184 public MenuItem
setOnMenuItemClickListener(OnMenuItemClickListener menuItemClickListener
) {
189 public ContextMenu
.ContextMenuInfo
getMenuInfo() {
194 public void setShowAsAction(int actionEnum
) {
199 public MenuItem
setShowAsActionFlags(int actionEnum
) {
204 public MenuItem
setActionView(View view
) {
209 public MenuItem
setActionView(int resId
) {
214 public View
getActionView() {
219 public MenuItem
setActionProvider(ActionProvider actionProvider
) {
224 public ActionProvider
getActionProvider() {
229 public boolean expandActionView() {
234 public boolean collapseActionView() {
239 public boolean isActionViewExpanded() {
244 public MenuItem
setOnActionExpandListener(OnActionExpandListener listener
) {