| org.eclipse.ui.menus.CommandContributionItem
Field Summary | |
final public static int | STYLE_CHECK A checked tool item or menu item. | final public static int | STYLE_PULLDOWN A ToolBar pulldown item. | final public static int | STYLE_PUSH A push button tool item or menu item. | final public static int | STYLE_RADIO A radio-button style menu item. |
Constructor Summary | |
public | CommandContributionItem(IServiceLocator serviceLocator, String id, String commandId, Map parameters, ImageDescriptor icon, ImageDescriptor disabledIcon, ImageDescriptor hoverIcon, String label, String mnemonic, String tooltip, int style) Create a CommandContributionItem to place in a ContributionManager.
Parameters: serviceLocator - a service locator that is most appropriate for thiscontribution. |
STYLE_CHECK | final public static int STYLE_CHECK(Code) | | A checked tool item or menu item.
|
STYLE_PULLDOWN | final public static int STYLE_PULLDOWN(Code) | | A ToolBar pulldown item.
|
STYLE_PUSH | final public static int STYLE_PUSH(Code) | | A push button tool item or menu item.
|
STYLE_RADIO | final public static int STYLE_RADIO(Code) | | A radio-button style menu item.
|
CommandContributionItem | public CommandContributionItem(IServiceLocator serviceLocator, String id, String commandId, Map parameters, ImageDescriptor icon, ImageDescriptor disabledIcon, ImageDescriptor hoverIcon, String label, String mnemonic, String tooltip, int style)(Code) | | Create a CommandContributionItem to place in a ContributionManager.
Parameters: serviceLocator - a service locator that is most appropriate for thiscontribution. Typically the local IWorkbenchWindow orIWorkbenchPartSite will be sufficient. Parameters: id - The id for this item. May be null . Itemswithout an id cannot be referenced later. Parameters: commandId - A command id for a defined command. Must not benull . Parameters: parameters - A map of strings to strings which represent parameter names tovalues. The parameter names must match those in the commanddefinition. Parameters: icon - An icon for this item. May be null . Parameters: disabledIcon - A disabled icon for this item. May be null . Parameters: hoverIcon - A hover icon for this item. May be null . Parameters: label - A label for this item. May be null . Parameters: mnemonic - A mnemonic for this item to be applied to the label. May benull . Parameters: tooltip - A tooltip for this item. May be null . Tooltipsare currently only valid for toolbar contributions. Parameters: style - The style of this menu contribution. See the STYLE_* contants. |
dispose | public void dispose()(Code) | | |
fill | public void fill(Menu parent, int index)(Code) | | |
fill | public void fill(ToolBar parent, int index)(Code) | | |
getCommand | ParameterizedCommand getCommand()(Code) | | |
isEnabled | public boolean isEnabled()(Code) | | |
update | public void update()(Code) | | |
|
|