private class SubMenuGuiImpl.SubMenuBody extends AbstractContainer<GuiOutputManager> implements MenuStructure<GuiOutputManager>, MouseWidgetsEnumerator
Modifier and Type | Field and Description |
---|---|
private WidgetId |
id
Widget ID.
|
location, mousePtr, nativeInsets, physicalLocation
Modifier | Constructor and Description |
---|---|
private |
SubMenuBody() |
Modifier and Type | Method and Description |
---|---|
Widget<GuiOutputManager> |
currentFocus(boolean recurse)
Get widget which is in focus.
|
void |
draw()
Draw widget.
|
protected void |
focusWorker(boolean direction)
Search for the next or previous focusable widget in the container and
set focus on it.
|
WidgetId |
getId()
Widget ID.
|
java.util.List<Widget> |
getMouseWidgets()
Returns the list of widgets that will be considered when registering mouse widgets by GUI driver.
|
Menu<GuiOutputManager> |
getParentMenu()
Returns the parent menu.
|
SubMenu<GuiOutputManager> |
getParentSubMenu()
Returns the parent menu.
|
private SubMenuGuiImpl |
getSubMenu()
Returns the outer instance.
|
java.util.List<Widget<GuiOutputManager>> |
getTabItemList()
Returns the tab item list for this container.
|
boolean |
isVisible()
Check if widget is visible.
|
void |
processKeyEvent(KeyInput event)
Process key event.
|
java.lang.String |
toString()
Returns a string representation of the object.
|
add, add, add, addContainerStateListener, addDirectly, belongsTo, checkWidget, childrenLocation, clipping, clipRectangle, copyState, currentFocus, cycleFocus, defaultFocus, destroy, detach, dimension, doLayout, dumpCurrentWidgets, dumpWidgets, endSizeChange, findMouseSource, firstFocus, focus, focusTraversable, formatDump, get, getClipRect, getEffectiveScrollableSize, getFocusInt, getIgnoreFocus, getLayout, getScrollableSize, hasFocusable, height, insets, lastFocus, minimumSize, moveAfterTabItem, moveBeforeTabItem, moveToBottom, moveToBottomInClass, moveToTop, moveToTopInClass, moveToZpos, nextFocus, normalizeZOrder, onWidgetAdded, onWidgetRemoved, prepareWidgets, prevFocus, reflectAncestorChange, reflectLocationChange, remove, removeContainerStateListener, repaint, replace, requestFocus, setFocus, setFocusInt, setHeight, setIgnoreFocus, setInsets, setLayout, setSize, setSize, setTabItemList, setWidth, startSizeChange, triggerContainerStateRedrawEnabled, unrealize, updateSizeWorker, widgets, widgetsAsList, width
_setHidden, _setVisible, activateDirectManipulation, addFocusListener, addKeyListener, afterConfigUpdateBase, ancestor, ancestorId, autoResize, bounds, clear, clearWidget, clipRectangle, clipRectangle, clipWith, config, copyColors, createMouseHoverAction, deactivateDirectManipulation, debug, disable, displayPhysicalLocation, drawCaret, enable, enclosingFrame, forceCursorOnFocus, forceVisibility, getActualBounds, getAndResetBitmap, getAndSetBitmap, getBitmapCopy, getCachedScreenLocation, getCachedScreenPhysicalLocation, getCustomMousePointer, getDefaultEvent, getEffectiveMousePointer, getLoadedMousePointer, getMenuMouse, getMouseActions, getPortableMouseEventCoordinates, getSelectedText, getState, getTextHeight, getTextHeightNative, getTextWidth, getTextWidth, getTextWidthNative, getTextWidthNative, getVisiblePart, getZOrderClass, hasFocus, hidden, hide, highlighted, ignoreAction, isCurrent, isDirectManipulationCapable, isDirectManipulationRequired, isDisplayed, isEnabled, isFocusable, isHeader, isRealized, isRepaintDisabled, isRMBEntrySupported, isScreenLocationCached, isTabStop, isThreeD, isTotallyObscured, isVisible, location, manageSystemActions, mouseActions, mouseClicked, mouseDragged, mouseEntered, mouseExited, mouseMoved, mousePressed, mouseReleased, mouseWheelMoved, moveToBottom, moveToTop, name, navigable, parent, parent, parentObject, parentOrSelf, parentOrSelfObject, physicalBounds, physicalDimension, physicalLocation, postprocessConfig, prepParentLocation, processDirectManipulationEvent, processEvent, processFocusEvent, processKeyListeners, processMnemonic, processMnemonicImpl, processSystemKey, raiseLegacyMouseEvents, refresh, registerWidgetStateListener, repaint, requestSync, resetBitmap, resizeTo, resolveFont, resolvePopupMenuId, resolveTitleFont, screen, screenDimension, screenHeight, screenLocation, screenPhysicalLocation, screenWidth, setBitmap, setCachedScreenLocation, setCachedScreenPhysicalLocation, setEnabled, setHidden, setHighlighted, setLocation, setLocation, setMousePointer, setParent, setPhysicalLocation, setState, setVisible, show, showPopupMenu, supportsCustomMousePointer, sync, topLevelWindow, translate, window
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getParentMenuContainer, getRootSubMenu
addFocusListener, addKeyListener, ancestor, ancestorId, bounds, clearWidget, config, defaultMousePtr, destroy, dimension, displayPhysicalLocation, drawCaret, enclosingFrame, enforceDefaultMousePtr, findMouseSource, focusTraversable, forceCursorOnFocus, forceVisibility, getActualBounds, getCustomMousePointer, getEffectiveMousePointer, getLegacyWidget, getLoadedMousePointer, getMenuMouse, getMouseActions, getSelectedText, getState, getVisiblePart, getZOrderClass, hasFocus, height, hidden, hide, highlighted, insets, isCurrent, isDirectManipulable, isDisplayed, isDroppable, isEnabled, isFocusable, isHeader, isRealized, isRepaintDisabled, isRMBEntrySupported, isTabStop, isThreeD, isTotallyObscured, isVisible, location, maySwitchFocus, minimumSize, moveToBottom, moveToTop, name, navigable, parent, parent, parentObject, parentOrSelf, parentOrSelfObject, physicalBounds, physicalDimension, physicalLocation, postprocessConfig, processDirectManipulationEvent, processEvent, processFocusEvent, processKeyListeners, processMnemonic, raiseLegacyMouseEvents, repaint, repaint, requestFocus, requestFocus, requestSync, resizeTo, resolvePopupMenuId, screen, screenLocation, screenPhysicalLocation, setEnabled, setHidden, setHighlighted, setLocation, setLocation, setMousePointer, setParent, setPhysicalLocation, setState, setVisible, show, supportsCustomMousePointer, topLevelWindow, unrealize, width, window
private WidgetId id
public WidgetId getId()
getId
in interface Widget<GuiOutputManager>
getId
in class AbstractWidget<GuiOutputManager>
public boolean isVisible()
isVisible
in interface Widget<GuiOutputManager>
isVisible
in class AbstractWidget<GuiOutputManager>
true
if widget is visible.public void draw()
draw
in interface Widget<GuiOutputManager>
draw
in class AbstractContainer<GuiOutputManager>
public void processKeyEvent(KeyInput event)
processKeyEvent
in interface Widget<GuiOutputManager>
processKeyEvent
in class AbstractContainer<GuiOutputManager>
event
- Key event to process.public java.lang.String toString()
toString
in class AbstractWidget<GuiOutputManager>
public java.util.List<Widget<GuiOutputManager>> getTabItemList()
getTabItemList
in interface Container<GuiOutputManager>
getTabItemList
in class AbstractContainer<GuiOutputManager>
public java.util.List<Widget> getMouseWidgets()
getMouseWidgets
in interface MouseWidgetsEnumerator
null
.public Menu<GuiOutputManager> getParentMenu()
getParentMenu
in interface MenuStructure<GuiOutputManager>
public SubMenu<GuiOutputManager> getParentSubMenu()
null
,
in this case the menu element is not located under a sub-menu.getParentSubMenu
in interface MenuStructure<GuiOutputManager>
public Widget<GuiOutputManager> currentFocus(boolean recurse)
The method allows to choose whether the focused widget is searched in the nested
containers (recurse == true
) or whether only this container is searched
(recurse == false
).
The override allows the submenu widget to become focused even without any of the child widgets
in focus. This allows the widget to process key events.
currentFocus
in interface Container<GuiOutputManager>
currentFocus
in class AbstractContainer<GuiOutputManager>
recurse
- The parameter controls whether the method should recurse to the nested
containers when searching for the focused widget.protected void focusWorker(boolean direction)
focusWorker
in class AbstractContainer<GuiOutputManager>
direction
- Widget search direction.private SubMenuGuiImpl getSubMenu()