protected class JMenu.AccessibleJMenu extends JMenuItem.AccessibleJMenuItem implements AccessibleSelection
JMenu.JComponent.AccessibleJComponent.AccessibleContainerHandler, JComponent.AccessibleJComponent.AccessibleFocusHandlerComponent.AccessibleAWTComponent.AccessibleAWTComponentHandler, Component.AccessibleAWTComponent.AccessibleAWTFocusHandleraccessibleContainerHandler, accessibleFocusHandleraccessibleAWTComponentHandler, accessibleAWTFocusHandlerACCESSIBLE_ACTION_PROPERTY, ACCESSIBLE_ACTIVE_DESCENDANT_PROPERTY, ACCESSIBLE_CARET_PROPERTY, ACCESSIBLE_CHILD_PROPERTY, ACCESSIBLE_COMPONENT_BOUNDS_CHANGED, ACCESSIBLE_DESCRIPTION_PROPERTY, ACCESSIBLE_HYPERTEXT_OFFSET, ACCESSIBLE_INVALIDATE_CHILDREN, ACCESSIBLE_NAME_PROPERTY, ACCESSIBLE_SELECTION_PROPERTY, ACCESSIBLE_STATE_PROPERTY, ACCESSIBLE_TABLE_CAPTION_CHANGED, ACCESSIBLE_TABLE_COLUMN_DESCRIPTION_CHANGED, ACCESSIBLE_TABLE_COLUMN_HEADER_CHANGED, ACCESSIBLE_TABLE_MODEL_CHANGED, ACCESSIBLE_TABLE_ROW_DESCRIPTION_CHANGED, ACCESSIBLE_TABLE_ROW_HEADER_CHANGED, ACCESSIBLE_TABLE_SUMMARY_CHANGED, ACCESSIBLE_TEXT_ATTRIBUTES_CHANGED, ACCESSIBLE_TEXT_PROPERTY, ACCESSIBLE_VALUE_PROPERTY, ACCESSIBLE_VISIBLE_DATA_PROPERTY, accessibleDescription, accessibleName, accessibleParentCLICK, DECREMENT, INCREMENT, TOGGLE_EXPAND, TOGGLE_POPUPCHARACTER, SENTENCE, WORD| Modifier | Constructor and Description |
|---|---|
protected |
JMenu.AccessibleJMenu() |
| Modifier and Type | Method and Description |
|---|---|
void |
addAccessibleSelection(int index)
Selects the accessible child with the specified index.
|
void |
clearAccessibleSelection()
Removes all possibly selected accessible children of this object from
the selection.
|
Accessible |
getAccessibleChild(int index)
Returns the accessible child with the specified
index. |
int |
getAccessibleChildrenCount()
Returns the number of accessible children of this object.
|
AccessibleRole |
getAccessibleRole()
Returns the accessible role of this object, which is
AccessibleRole.MENU for the AccessibleJMenu. |
AccessibleSelection |
getAccessibleSelection()
Returns the accessible selection of this object.
|
Accessible |
getAccessibleSelection(int index)
Returns the selected accessible child with the specified
index. |
int |
getAccessibleSelectionCount()
Returns the number of selected accessible children.
|
boolean |
isAccessibleChildSelected(int index)
Returns
true if the accessible child with the specified
index is selected, false otherwise. |
void |
removeAccessibleSelection(int index)
Removes the item with the specified index from the selection.
|
void |
selectAllAccessibleSelection()
AccessibleJMenu don't support multiple selection, so this method
does nothing.
|
stateChangeddoAccessibleAction, getAccessibleAction, getAccessibleActionCount, getAccessibleActionDescription, getAccessibleIcon, getAccessibleName, getAccessibleRelationSet, getAccessibleStateSet, getAccessibleText, getAccessibleValue, getAfterIndex, getAtIndex, getBeforeIndex, getCaretPosition, getCharacterAttribute, getCharacterBounds, getCharCount, getCurrentAccessibleValue, getIndexAtPoint, getMaximumAccessibleValue, getMinimumAccessibleValue, getSelectedText, getSelectionEnd, getSelectionStart, setCurrentAccessibleValueaddPropertyChangeListener, getAccessibleDescription, getAccessibleKeyBinding, getBorderTitle, getTitledBorderText, getToolTipText, removePropertyChangeListenergetAccessibleAtaddFocusListener, contains, getAccessibleComponent, getAccessibleIndexInParent, getAccessibleParent, getBackground, getBounds, getCursor, getFont, getFontMetrics, getForeground, getLocale, getLocation, getLocationOnScreen, getSize, isEnabled, isFocusTraversable, isShowing, isVisible, removeFocusListener, requestFocus, setBackground, setBounds, setCursor, setEnabled, setFont, setForeground, setLocation, setSize, setVisiblefirePropertyChange, getAccessibleEditableText, getAccessibleTable, setAccessibleDescription, setAccessibleName, setAccessibleParentclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitaddFocusListener, contains, getAccessibleAt, getBackground, getBounds, getCursor, getFont, getFontMetrics, getForeground, getLocation, getLocationOnScreen, getSize, isEnabled, isFocusTraversable, isShowing, isVisible, removeFocusListener, requestFocus, setBackground, setBounds, setCursor, setEnabled, setFont, setForeground, setLocation, setSize, setVisibleprotected JMenu.AccessibleJMenu()
public int getAccessibleChildrenCount()
getAccessibleChildrenCount in class JComponent.AccessibleJComponentAccessibleContext.getAccessibleChild(int)public Accessible getAccessibleChild(int index)
index.getAccessibleChild in class JComponent.AccessibleJComponentindex - the index of the child to fetchindexComponent.AccessibleAWTComponent.getAccessibleChildrenCount()public AccessibleSelection getAccessibleSelection()
this here.getAccessibleSelection in class AccessibleContextAccessibleSelectionpublic Accessible getAccessibleSelection(int index)
index.getAccessibleSelection in interface AccessibleSelectionindex - the index of the accessible selected child to returnindexAccessibleSelection.getAccessibleSelectionCount()public boolean isAccessibleChildSelected(int index)
true if the accessible child with the specified
index is selected, false otherwise.isAccessibleChildSelected in interface AccessibleSelectionindex - the index of the accessible child to checktrue if the accessible child with the specified
index is selected, false otherwisepublic AccessibleRole getAccessibleRole()
AccessibleRole.MENU for the AccessibleJMenu.getAccessibleRole in class JMenuItem.AccessibleJMenuItemAccessibleRolepublic int getAccessibleSelectionCount()
0 if no item is selected, or 1 if an item
is selected. AccessibleJMenu can have maximum 1 selected item.getAccessibleSelectionCount in interface AccessibleSelectionpublic void addAccessibleSelection(int index)
addAccessibleSelection in interface AccessibleSelectionindex - the index of the accessible child to selectpublic void removeAccessibleSelection(int index)
removeAccessibleSelection in interface AccessibleSelectionindex - the index of the selected item to remove from the selectionpublic void clearAccessibleSelection()
clearAccessibleSelection in interface AccessibleSelectionpublic void selectAllAccessibleSelection()
selectAllAccessibleSelection in interface AccessibleSelection