MenuComponent
is the superclass
of all menu-related components. In this respect, the class
MenuComponent
is analogous to the abstract superclass
Component
for AWT components.
Menu components receive and process AWT events, just as components do,
through the method processEvent
.
Modifier and Type | Class and Description |
---|---|
protected abstract class | MenuComponent.
Inner class of |
Modifier and Type | Field and Description |
---|---|
private transient volatile AccessControlContext | acc
Deprecated
as a consequence of
AccessControlContext being deprecated.
|
pack-priv AccessibleContext | accessibleContext
MenuComponent will contain all of the methods in interface Accessible, though it won't actually implement the interface - that will be up to the individual objects which extend MenuComponent. |
pack-priv static final String | |
private transient volatile AppContext | appContext
The |
private volatile Font | font
The menu component's font. |
pack-priv static final String | |
private volatile String | name
The menu component's name, which defaults to |
private volatile boolean | nameExplicitlySet
A variable to indicate whether a name is explicitly set. |
pack-priv volatile boolean | newEventsOnly
Defaults to |
pack-priv transient volatile MenuContainer | |
pack-priv transient volatile MenuComponentPeer | |
private static final long | serialVersionUID
Use serialVersionUID from JDK 1.1 for interoperability. |
Access | Constructor and Description |
---|---|
public |
Modifier and Type | Method and Description |
---|---|
pack-priv String | Returns: a name for thisMenuComponent Constructs a name for this |
public final void | |
pack-priv void | |
pack-priv boolean | |
pack-priv final AccessControlContext | |
pack-priv int | Returns: -1 if this object doesn't contain the child, otherwise, index of the child.MenuComponent whose index we are interested in. child)Gets the index of the child within this MenuComponent. |
public AccessibleContext | Returns: theAccessibleContext of this
MenuComponent Gets the |
pack-priv int | Returns: -1 if this object does not have an accessible parent; otherwise, the index of the child in its accessible parent.Gets the index of this object in its accessible parent. |
pack-priv AccessibleStateSet | Returns: an instance ofAccessibleStateSet
containing the current state set of the objectGets the state of this object. |
pack-priv final ComponentFactory | |
public Font | Returns: the font used in this menu component, if there is one;null otherwiseGets the font used for this menu component. |
pack-priv final Font | |
public String | |
public MenuContainer | Returns: the menu component containing this menu component, ornull if this menu component
is the outermost component, the menu bar itselfReturns the parent container for this menu component. |
pack-priv final MenuContainer | |
protected final Object | Returns: this component's locking objectGets this component's locking object (the object that owns the thread synchronization monitor) for AWT component-tree and layout operations. |
protected String | Returns: the parameter string of this menu componentReturns a string representing the state of this
|
public boolean | Returns: unconditionally returns falsethe event which is to take place evt)
Deprecated
As of JDK version 1.1, replaced by
Posts the specified event to the menu.
dispatchEvent .
|
protected void | |
private void | readObject(ObjectInputStream
the s)ObjectInputStream to readReads the menu component from an object input stream. |
public void | |
public void | |
public void | |
public String | Returns: a string representation of this menu componentOverrides java. |