Class AbstractMenuItem
- java.lang.Object
-
- com.googlecode.wicket.jquery.ui.widget.menu.AbstractMenuItem
-
- All Implemented Interfaces:
IMenuItem
,Serializable
,org.apache.wicket.util.io.IClusterable
- Direct Known Subclasses:
MenuItem
public abstract class AbstractMenuItem extends Object implements IMenuItem
Base class forMenu
item- Since:
- 1.4.2, 6.2.2
- Author:
- Sebastien Briquet - sebfz1
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description AbstractMenuItem(org.apache.wicket.model.IModel<String> title, String icon)
Constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getIcon()
Gets the icon css class being displayed in theMenu
String
getId()
Gets the menu-item markup idList<IMenuItem>
getItems()
Gets theList
of submenu-itemsorg.apache.wicket.model.IModel<String>
getTitle()
Gets the menu-item titleboolean
isEnabled()
Indicates whether the menu-item is enabledvoid
setEnabled(boolean enabled)
Sets whether the menu-item is enabledvoid
setIcon(String icon)
Sets the icon css class being displayed in theMenu
(ie: ui-my-icon)void
setTitle(org.apache.wicket.model.IModel<String> title)
Sets the menu-item title
-
-
-
Constructor Detail
-
AbstractMenuItem
public AbstractMenuItem(org.apache.wicket.model.IModel<String> title, String icon)
Constructor- Parameters:
title
-IModel
that represent the title of the menu-itemicon
- the icon css class;'ui-icon-blank'
orJQueryIcon.BLANK
may be used to display no icon.
-
-
Method Detail
-
getId
public String getId()
Description copied from interface:IMenuItem
Gets the menu-item markup id
-
getTitle
public org.apache.wicket.model.IModel<String> getTitle()
Description copied from interface:IMenuItem
Gets the menu-item title
-
setTitle
public void setTitle(org.apache.wicket.model.IModel<String> title)
Sets the menu-item title- Parameters:
title
- the menu-item title
-
getIcon
public String getIcon()
Description copied from interface:IMenuItem
Gets the icon css class being displayed in theMenu
-
setIcon
public void setIcon(String icon)
Sets the icon css class being displayed in theMenu
(ie: ui-my-icon)- Parameters:
icon
- the icon css class
-
isEnabled
public boolean isEnabled()
Description copied from interface:IMenuItem
Indicates whether the menu-item is enabled
-
setEnabled
public void setEnabled(boolean enabled)
Sets whether the menu-item is enabled- Parameters:
enabled
- true or false
-
-