Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

com.flexstor.common.awt.menu
Class MenuItem  view MenuItem download MenuItem.java

java.lang.Object
  extended byjava.awt.MenuComponent
      extended byjava.awt.MenuItem
          extended bycom.flexstor.common.awt.menu.MenuItem
All Implemented Interfaces:
javax.accessibility.Accessible, com.flexstor.common.awt.ActionComponentI, java.io.Serializable

public class MenuItem
extends java.awt.MenuItem
implements com.flexstor.common.awt.ActionComponentI

This class adds an identifier to each menu item in order to uniquely determine an item independant of its label. It sends a ActionEvent with its action id to its container class when selected.


Nested Class Summary
 
Nested classes inherited from class java.awt.MenuItem
java.awt.MenuItem.AccessibleAWTMenuItem
 
Nested classes inherited from class java.awt.MenuComponent
java.awt.MenuComponent.AccessibleAWTMenuComponent
 
Field Summary
(package private)  int nActionId
           
 
Fields inherited from class java.awt.MenuItem
 
Fields inherited from class java.awt.MenuComponent
 
Fields inherited from interface com.flexstor.common.awt.ActionComponentI
ACTION_ADD, ACTION_ADD_ALL, ACTION_ADDRESS_BOOK, ACTION_ADM_OPEN_UGSD, ACTION_ADV_SEARCH, ACTION_ARCHIVE, ACTION_BASIC_SEARCH, ACTION_BROWSE_HIGHCPY, ACTION_BROWSE_HIGHRES, ACTION_BROWSE_LOCAL, ACTION_BROWSE_LOWCPY, ACTION_BROWSE_LOWRES, ACTION_BROWSE_MACHINES, ACTION_BROWSE_NEW_FOLDER, ACTION_BROWSE_PICTURE_GALLERY_TEMPLATES, ACTION_BROWSE_REFRESH, ACTION_BROWSE_SERVER, ACTION_BROWSE_SOURCE_FILES, ACTION_BROWSE_THUMB, ACTION_CANCEL, ACTION_CHANGE_APP, ACTION_CHECKBOX_LOCAL, ACTION_CHECKBOX_MKCOPY, ACTION_CHECKBOX_MKTHUMB, ACTION_CLASSIFY, ACTION_CLOSE, ACTION_CLOSE_FULL_THUMB, ACTION_COLLAPSE_TREE_ROW, ACTION_CREATE_FULL_THUMB, ACTION_DEBUG_HIDE_INSTANCE_IDS, ACTION_DEBUG_SHOW_INSTANCE_IDS, ACTION_DEBUG_SHOW_REG_DEBUGGER, ACTION_DELETE, ACTION_DELETE_ALL, ACTION_DELETE_ASSET, ACTION_DELETE_TREE_ROW, ACTION_DISP_FULLSIZE, ACTION_DISP_RECORD, ACTION_DISP_SUMMARY, ACTION_DISP_THUMB_DATA, ACTION_DISP_THUMB_FLAT, ACTION_DISP_THUMB_RECORD, ACTION_DISP_THUMBNAIL, ACTION_EDT_COPY, ACTION_EDT_CUT, ACTION_EDT_DELETE, ACTION_EDT_NEW_BUCKET, ACTION_EDT_NEW_ELEMENT, ACTION_EDT_PASTE, ACTION_EXPAND_TREE_ROW, ACTION_EXPORT, ACTION_FIELD_VALUE_CHANGED, ACTION_FILEBASED_SEARCH, ACTION_FSV_CLOSE, ACTION_FSV_COPY, ACTION_FSV_DRAG_SELECT, ACTION_FSV_FIT_HEIGHT, ACTION_FSV_FIT_WIDTH, ACTION_FSV_FIT_WINDOW, ACTION_FSV_NEXT_IMAGE, ACTION_FSV_PRINT, ACTION_FSV_PRIOR_IMAGE, ACTION_FSV_RESTORE, ACTION_FSV_ROTATE_FLIP, ACTION_FSV_ROTATE_LEFT, ACTION_FSV_ROTATE_RIGHT, ACTION_FSV_SELECT_ALL, ACTION_FSV_ZOOM_IN, ACTION_FSV_ZOOM_OUT, ACTION_FSV_ZOOM_TO_SELECTION, ACTION_FULL_SIZE_AVAILABLE, ACTION_FULL_SIZE_ERROR, ACTION_FULL_TEXT_SEARCH, ACTION_GO_SAVED_SEARCH, ACTION_GOTO_PAGE, ACTION_HLP_ABOUT, ACTION_HLP_CONTENTS, ACTION_HLP_CONTEXT, ACTION_IMPORT, ACTION_IMPORT_REFRESH, ACTION_INSERT_PICTURE_GALLERY_TEMPLATES, ACTION_MODIFY, ACTION_NEXT_PAGE, ACTION_OK, ACTION_OPEN, ACTION_OPT_ADD_DATA, ACTION_OPT_APPLY, ACTION_OPT_CHECK_IN, ACTION_OPT_CHECK_OUT, ACTION_OPT_CLEAR, ACTION_OPT_CLEAR_ALL, ACTION_OPT_CLEAR_ALL_MARKS, ACTION_OPT_CREATE_REPORT, ACTION_OPT_DELETE_ELEMENTS, ACTION_OPT_DISCARD, ACTION_OPT_EDITMODE, ACTION_OPT_KEEP, ACTION_OPT_KEEP_ON_APPLY, ACTION_OPT_LOCATIONS, ACTION_OPT_MARK, ACTION_OPT_PROCESS, ACTION_OPT_REFRESH, ACTION_OPT_REFRESH_THUMBNAIL, ACTION_OPT_RELEASE_LOCK, ACTION_OPT_REMOVE, ACTION_OPT_SAVED_SEARCH, ACTION_OPT_SEARCH, ACTION_OPT_SETTINGS, ACTION_OPT_STOP, ACTION_OPT_UNMARK, ACTION_OPT_UPDATE, ACTION_OPT_VIEW_TRANSACTIONS, ACTION_OPT_VIEWLOG, ACTION_OPT_VISUAL_SEARCH, ACTION_PASTE_ASSET, ACTION_PREV_PAGE, ACTION_PUT_ELEMENT, ACTION_RESTORE, ACTION_RPT_FIRST, ACTION_RPT_GEN_CSV, ACTION_RPT_GEN_HTML, ACTION_RPT_GEN_PDF, ACTION_RPT_GOTO, ACTION_RPT_LAST, ACTION_RPT_NEXT, ACTION_RPT_PREV, ACTION_RPT_PRINT, ACTION_RPT_SHOW_TOC, ACTION_RPT_ZOOM_100, ACTION_RPT_ZOOM_150, ACTION_RPT_ZOOM_200, ACTION_RPT_ZOOM_50, ACTION_RPT_ZOOM_75, ACTION_SAVE_SEARCH, ACTION_SAVE_SEARCH_AS, ACTION_SEARCH, ACTION_SELECT_TREE_ROW, ACTION_SEND, ACTION_SERVER_MAINTENANCE, ACTION_SRCH_CHANGE_APPL, ACTION_SRCH_FEWER, ACTION_SRCH_GO, ACTION_SRCH_GO_SAVED, ACTION_SRCH_IGNORE_CASE, ACTION_SRCH_MODE_ADV, ACTION_SRCH_MODE_BASIC, ACTION_SRCH_MODE_FILEBASED, ACTION_SRCH_MODE_FULL_TEXT, ACTION_SRCH_MORE, ACTION_SRCH_NEW_FRAME, ACTION_THUMB_CREATE_FULL_THUMB, ACTION_THUMB_VIEW_ELEMENT_DETAILS, ACTION_THUMB_VIEW_MULTI_PAGE, ACTION_TRANSACTION_LOGGING, ACTION_TREE_COLLAPSE_ALL, ACTION_TREE_COLLAPSE_BRANCH, ACTION_TREE_EXPAND_ALL, ACTION_TREE_EXPAND_BRANCH, ACTION_TREE_EXPAND_ONE_LEVEL, ACTION_UTL_TRASH_CAN, ACTION_UTL_VIEW_TRANSACTIONS, ACTION_VIEW_ELEMENT_DETAILS, ACTION_VIEW_HISTORY, ACTION_VIEW_MARKED_ITEMS, ACTION_VIEW_MULTI_PAGE, ACTION_VIEW_RELOAD_THUMBNAIL, ACTION_VIEW_VERSIONS, ACTION_VIR_EXECUTE, ACTION_VIR_NEW_FRAME, ACTION_VIR_SET_WEIGHTS, IDENTIFIER
 
Constructor Summary
MenuItem(int nTextId, int nActionId)
          Create a new MenuItem with the given label id(text resource number) and action id(defined in Constants).
MenuItem(int nTextId, int nActionId, int nShortcutKey, boolean bUseShift)
          Create a new MenuItem with the given label id(text resource number), action id(defined in Constants), and menu shortcut key.
MenuItem(java.lang.String sLabel, int nActionId)
          Create a new MenuItem with the given label and action id(defined in Constants).
MenuItem(java.lang.String sLabel, int nActionId, int nShortcutKey, boolean bUseShift)
          Create a new MenuItem with the given label and action id(defined in Constants).
 
Method Summary
 void addNotify()
          Creates the native peer for this object.
 int getActionId()
          Gets the menu item action id
 java.lang.String paramString()
          Returns the String parameter of the menu item.
protected  void processActionEvent(java.awt.event.ActionEvent e)
          Processes the specified event by dispatching it to any registered listeners.
 
Methods inherited from class java.awt.MenuItem
addActionListener, deleteShortcut, disable, disableEvents, enable, enable, enableEvents, getAccessibleContext, getActionCommand, getActionListeners, getLabel, getListeners, getShortcut, isEnabled, processEvent, removeActionListener, setActionCommand, setEnabled, setLabel, setShortcut
 
Methods inherited from class java.awt.MenuComponent
dispatchEvent, getFont, getName, getParent, getPeer, getTreeLock, postEvent, removeNotify, setFont, setName, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface com.flexstor.common.awt.ActionComponentI
addActionListener, removeActionListener, setEnabled
 

Field Detail

nActionId

int nActionId
Constructor Detail

MenuItem

public MenuItem(int nTextId,
                int nActionId)
Create a new MenuItem with the given label id(text resource number) and action id(defined in Constants).


MenuItem

public MenuItem(int nTextId,
                int nActionId,
                int nShortcutKey,
                boolean bUseShift)
Create a new MenuItem with the given label id(text resource number), action id(defined in Constants), and menu shortcut key.


MenuItem

public MenuItem(java.lang.String sLabel,
                int nActionId)
Create a new MenuItem with the given label and action id(defined in Constants).


MenuItem

public MenuItem(java.lang.String sLabel,
                int nActionId,
                int nShortcutKey,
                boolean bUseShift)
Create a new MenuItem with the given label and action id(defined in Constants).

Method Detail

addNotify

public void addNotify()
Description copied from class: java.awt.MenuItem
Creates the native peer for this object.


getActionId

public int getActionId()
Gets the menu item action id

Specified by:
getActionId in interface com.flexstor.common.awt.ActionComponentI

processActionEvent

protected void processActionEvent(java.awt.event.ActionEvent e)
Description copied from class: java.awt.MenuItem
Processes the specified event by dispatching it to any registered listeners.


paramString

public java.lang.String paramString()
Returns the String parameter of the menu item.