| Package | org.aswing |
| Interface | public interface MenuElement |
| Implementors | JMenu, JMenuBar, JMenuItem, JPopupMenu |
MenuSelectionManager
to handle selection and navigation in menu hierarchies.
| Method | Defined by | ||
|---|---|---|---|
|
This method should return the Component used to paint the receiving element.
| MenuElement | ||
|
getSubElements():Array
This method should return an array containing the sub-elements for the receiving menu element
| MenuElement | ||
|
isInUse():Boolean
Returns whether the menu element is in use or not.
| MenuElement | ||
|
menuSelectionChanged(isIncluded:Boolean):void
Call by the
MenuSelectionManager when the
MenuElement is added or remove from
the menu selection. | MenuElement | ||
|
processKeyEvent(code:uint):void
Precess the selection when key typed.
| MenuElement | ||
|
setInUse(b:Boolean):void
Sets whether the menu element is in use.
| MenuElement | ||
| getMenuComponent | () | method |
public function getMenuComponent():ComponentThis method should return the Component used to paint the receiving element. The returned component will be used to convert events and detect if an event is inside a MenuElement's component.
ReturnsComponent —
the Component value
|
| getSubElements | () | method |
public function getSubElements():ArrayThis method should return an array containing the sub-elements for the receiving menu element
ReturnsArray — an array of MenuElements
|
| isInUse | () | method |
public function isInUse():BooleanReturns whether the menu element is in use or not.
ReturnsBoolean |
| menuSelectionChanged | () | method |
public function menuSelectionChanged(isIncluded:Boolean):void
Call by the MenuSelectionManager when the
MenuElement is added or remove from
the menu selection.
isIncluded:Boolean |
| processKeyEvent | () | method |
public function processKeyEvent(code:uint):voidPrecess the selection when key typed.
Parameterscode:uint |
| setInUse | () | method |
public function setInUse(b:Boolean):voidSets whether the menu element is in use.
Parametersb:Boolean |