|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
|
+--java.awt.Component
|
+--amber.server.component.ComponentHandler
|
+--amber.server.component.MenuComponentHandler
|
+--amber.server.component.MenuItemHandler
|
+--amber.server.component.MenuHandler
|
+--amber.server.component.PopupMenuHandler
This class corresponds to a standard java.awt.Menu component. It differs in terms of being Amber aware. For this reason the component communicates with the remote client to perform the standard operations.
The remote client class also responds to information stored in the parameters field of the XYConstraints object when this handler is added to a panel. The allowed parameters are separated in the string by '|' characters. Any unused trailing parameters are optional and will assume default values, however the parameter order is fixed.
For example, if the component takes 4 parameters which are ints, a valid parameter string would be:
"1|2|3"
In this case the fourth parameter would assume the default value.
The parameter elements for this component are:
| Name | Type | Description | Repeats | Default |
|---|---|---|---|---|
| Menu Type | int | For this class the value MUST BE 0 | No | 0 |
| Menu Label | int | The label of the menu | No |
ApplicationInterface,
ComponentHandler,
XYConstraints, Serialized Form| Inner classes inherited from class java.awt.Component |
java.awt.Component.AccessibleAWTComponent |
| Fields inherited from class amber.server.component.MenuHandler |
items, tearOff |
| Fields inherited from class amber.server.component.MenuItemHandler |
actionCommand, enabled, label |
| Fields inherited from class amber.server.component.MenuComponentHandler |
name, parent |
| Fields inherited from class amber.server.component.ComponentHandler |
active, ApplicationId, CancelReturn, dataEncoder, DefaultTimeout, enabledState, encoderBytes, id, InvalidId, MaximumId, NoReturn, OkCancelType, OkReturn, OkType, OkYesReturn, parentPage, responsePackets, timeoutValue, UnchangeableInvalidId, visibleState, YesNoCancelType, YesNoType, YesReturn |
| Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
| Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
PopupMenuHandler()
Default constructor. |
|
PopupMenuHandler(ApplicationInterface pageHandler)
The initialising constructor. |
|
PopupMenuHandler(ApplicationInterface pageHandler,
java.lang.String label)
The initialising constructor. |
|
PopupMenuHandler(int id,
ApplicationInterface pageHandler)
The initialising constructor. |
|
PopupMenuHandler(int id,
ApplicationInterface pageHandler,
java.lang.String label)
The initialising constructor. |
|
| Method Summary | |
int |
getBaseOffset()
This function returns the base offset that all menu components off this menu must reference. |
java.lang.String |
getDefaultParameters()
This function returns the default parameters string required by the component. |
int |
getIdOffset(int id)
This function returns what the input ID would be if it were offset by the base offset. |
java.lang.String |
getPanelType()
This function returns the panel component to use with this class. |
int |
removeIdOffset(int id)
This function returns what the input ID would be if it were not offset by the base offset. |
void |
show(int x,
int y)
Shows the popup menu at the x, y position relative to the parent container. |
| Methods inherited from class amber.server.component.MenuHandler |
add, add, addSeparator, deleteShortcut, deleteShortcut, forwardPacket, getItem, getItemCount, getShortcutMenuItem, insert, insert, insertSeparator, isMyId, isTearOff, paramString, processCurrentPacket, remove, remove, removeAll, resetState, setActive |
| Methods inherited from class amber.server.component.MenuItemHandler |
getLabel, getShortcut, isEnabled, setEnabled, setLabel, setShortcut |
| Methods inherited from class amber.server.component.MenuComponentHandler |
getId, getIdBaseOffset, getMenuParent, getName, getTopMenuParent, removeIdBaseOffset, sendPacket, sendPacketAndBlock, setName, toString |
| Methods inherited from class java.awt.Component |
action, add, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addPropertyChangeListener, addPropertyChangeListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, deliverEvent, disable, disableEvents, dispatchEvent, doLayout, enable, enable, enableEvents, enableInputMethods, firePropertyChange, getAccessibleContext, getAlignmentX, getAlignmentY, getBackground, getBounds, getColorModel, getComponentAt, getComponentAt, getComponentOrientation, getCursor, getDropTarget, getFont, getFontMetrics, getForeground, getGraphics, getGraphicsConfiguration, getHeight, getInputContext, getInputMethodRequests, getListeners, getLocale, getLocation, getLocationOnScreen, getMaximumSize, getMinimumSize, getParent, getPeer, getPreferredSize, getSize, getToolkit, getTreeLock, getWidth, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, invalidate, isDisplayable, isDoubleBuffered, isFocusTraversable, isLightweight, isOpaque, isShowing, isValid, keyDown, keyUp, layout, list, list, list, list, list, locate, location, lostFocus, minimumSize, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paint, paintAll, postEvent, preferredSize, prepareImage, prepareImage, print, printAll, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, remove, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, reshape, resize, resize, setBounds, setBounds, setComponentOrientation, setDropTarget, setLocale, setLocation, setLocation, setSize, setSize, show, show, size, transferFocus, update, validate |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface amber.server.component.MenuContainer |
getFont |
| Constructor Detail |
public PopupMenuHandler()
public PopupMenuHandler(ApplicationInterface pageHandler)
pageHandler - The handle to the main ApplicationInterface which handles the functions of page overall.
residing on the browser.
public PopupMenuHandler(ApplicationInterface pageHandler,
java.lang.String label)
pageHandler - The handle to the main ApplicationInterface which handles the functions of page overall.
residing on the browser.label - The label for this menu item.
public PopupMenuHandler(int id,
ApplicationInterface pageHandler)
id - The int containing the id of the corresponding remote component
residing on the browser.pageHandler - The handle to the main ApplicationInterface which handles the functions of page overall.
public PopupMenuHandler(int id,
ApplicationInterface pageHandler,
java.lang.String label)
id - The int containing the id of the corresponding remote component
residing on the browser.pageHandler - The handle to the main ApplicationInterface which handles the functions of page overall.label - The label for this menu item.| Method Detail |
public void show(int x,
int y)
x - the x coordinate position to popup the menuy - the y coordinate position to popup the menupublic int getBaseOffset()
getBaseOffset in interface BaseMenupublic int getIdOffset(int id)
getIdOffset in interface BaseMenuid - int ID value to offset.public int removeIdOffset(int id)
removeIdOffset in interface BaseMenuid - int ID value including offset.public java.lang.String getDefaultParameters()
getDefaultParameters in class ComponentHandlerpublic java.lang.String getPanelType()
getPanelType in class MenuHandler
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||