protected class JList.AccessibleJList extends JComponent.AccessibleJComponent implements javax.accessibility.AccessibleSelection, java.beans.PropertyChangeListener, javax.swing.event.ListSelectionListener, javax.swing.event.ListDataListener
JList.| Modifier and Type | Class and Description |
|---|---|
protected class |
JList.AccessibleJList.AccessibleJListChild
Provides accessibility support for list elements in
JLists. |
JComponent.AccessibleJComponent.AccessibleContainerHandler, JComponent.AccessibleJComponent.AccessibleFocusHandleraccessibleContainerHandler, accessibleFocusHandlerACCESSIBLE_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, accessibleParent| Constructor and Description |
|---|
JList.AccessibleJList()
Create a new AccessibleJList.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addAccessibleSelection(int i)
Adds the accessible item with the specified index to the selected items.
|
void |
clearAccessibleSelection()
Remove all selection items from the selection.
|
void |
contentsChanged(javax.swing.event.ListDataEvent event)
Receives notification when items have changed in the
JList. |
javax.accessibility.Accessible |
getAccessibleAt(java.awt.Point p)
Returns the accessible child at the visual location
p
(relative to the upper left corner of the JList). |
javax.accessibility.Accessible |
getAccessibleChild(int n)
Returns the n-th accessible child of this
JList. |
int |
getAccessibleChildrenCount()
Returns the number of accessible children in the
JList. |
javax.accessibility.AccessibleRole |
getAccessibleRole()
Returns the accessible role for
JList,
AccessibleRole.LIST. |
javax.accessibility.Accessible |
getAccessibleSelection(int n)
Returns the n-th selected accessible child.
|
int |
getAccessibleSelectionCount()
Returns the number of selected accessible children.
|
javax.accessibility.AccessibleStateSet |
getAccessibleStateSet()
Return the state set of the
JList. |
void |
intervalAdded(javax.swing.event.ListDataEvent event)
Receives notification when items are inserted into the
JList. |
void |
intervalRemoved(javax.swing.event.ListDataEvent event)
Receives notification when items are removed from the
JList. |
boolean |
isAccessibleChildSelected(int n)
Returns
true if the n-th child is selected,
false otherwise. |
void |
propertyChange(java.beans.PropertyChangeEvent e)
Receives notification about changes of the
JList's
properties. |
void |
removeAccessibleSelection(int i)
Removes the accessible item with the specified index to the selection.
|
void |
selectAllAccessibleSelection()
Selects all items if multiple selections are supported.
|
void |
valueChanged(javax.swing.event.ListSelectionEvent event)
Receices notification when the list selection is changed.
|
addPropertyChangeListener, getAccessibleDescription, getAccessibleKeyBinding, getAccessibleName, getBorderTitle, getTitledBorderText, getToolTipText, removePropertyChangeListenerfirePropertyChange, getAccessibleAction, getAccessibleEditableText, getAccessibleIcon, getAccessibleRelationSet, getAccessibleSelection, getAccessibleTable, getAccessibleText, getAccessibleValue, setAccessibleDescription, setAccessibleName, setAccessibleParentclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitaddFocusListener, contains, getBackground, getBounds, getCursor, getFont, getFontMetrics, getForeground, getLocation, getLocationOnScreen, getSize, isEnabled, isFocusTraversable, isShowing, isVisible, removeFocusListener, requestFocus, setBackground, setBounds, setCursor, setEnabled, setFont, setForeground, setLocation, setSize, setVisiblepublic JList.AccessibleJList()
public int getAccessibleSelectionCount()
getAccessibleSelectionCount in interface javax.accessibility.AccessibleSelectionpublic javax.accessibility.Accessible getAccessibleSelection(int n)
getAccessibleSelection in interface javax.accessibility.AccessibleSelectionn - the index of the selected child to returnAccessibleSelection.getAccessibleSelectionCount()public boolean isAccessibleChildSelected(int n)
true if the n-th child is selected,
false otherwise.isAccessibleChildSelected in interface javax.accessibility.AccessibleSelectionn - the index of the child of which the selected state is queriedtrue if the n-th child is selected,
false otherwisepublic void addAccessibleSelection(int i)
addAccessibleSelection in interface javax.accessibility.AccessibleSelectioni - the index of the item to add to the selectionpublic void removeAccessibleSelection(int i)
removeAccessibleSelection in interface javax.accessibility.AccessibleSelectioni - the index of the item to be removed from the selectionpublic void clearAccessibleSelection()
clearAccessibleSelection in interface javax.accessibility.AccessibleSelectionpublic void selectAllAccessibleSelection()
selectAllAccessibleSelection in interface javax.accessibility.AccessibleSelectionpublic void valueChanged(javax.swing.event.ListSelectionEvent event)
AccessibleContext.ACCESSIBLE_VISIBLE_DATA_PROPERTY and the second
with AccessibleContext.ACCESSIBLE_SELECTION_PROPERTY.valueChanged in interface javax.swing.event.ListSelectionListenerevent - the list selection eventpublic void contentsChanged(javax.swing.event.ListDataEvent event)
JList. This method fires a property change event with
AccessibleContext.ACCESSIBLE_VISIBLE_DATA_PROPERTY.contentsChanged in interface javax.swing.event.ListDataListenerevent - the list data eventpublic void intervalAdded(javax.swing.event.ListDataEvent event)
JList. This method fires a property change event with
AccessibleContext.ACCESSIBLE_VISIBLE_DATA_PROPERTY.intervalAdded in interface javax.swing.event.ListDataListenerevent - the list data eventpublic void intervalRemoved(javax.swing.event.ListDataEvent event)
JList. This method fires a property change event with
AccessibleContext.ACCESSIBLE_VISIBLE_DATA_PROPERTY.intervalRemoved in interface javax.swing.event.ListDataListenerevent - the list data eventpublic void propertyChange(java.beans.PropertyChangeEvent e)
JList's
properties. This is used to re-register this object as listener to
the data model and selection model when the data model or selection model
changes.propertyChange in interface java.beans.PropertyChangeListenere - the property change eventpublic javax.accessibility.AccessibleStateSet getAccessibleStateSet()
JList.getAccessibleStateSet in class JComponent.AccessibleJComponentJListAccessibleStatepublic javax.accessibility.AccessibleRole getAccessibleRole()
JList,
AccessibleRole.LIST.getAccessibleRole in class JComponent.AccessibleJComponentJListAccessibleRolepublic javax.accessibility.Accessible getAccessibleAt(java.awt.Point p)
p
(relative to the upper left corner of the JList). If there
is no child at that location, this returns null.getAccessibleAt in interface javax.accessibility.AccessibleComponentp - the screen location for which to return the accessible childnull if there is no child at that locationpublic int getAccessibleChildrenCount()
JList.getAccessibleChildrenCount in class JComponent.AccessibleJComponentJListAccessibleContext.getAccessibleChild(int)public javax.accessibility.Accessible getAccessibleChild(int n)
JList. This will
be an instance of JList.AccessibleJList.AccessibleJListChild. If there is no child
at that index, null is returned.getAccessibleChild in class JComponent.AccessibleJComponentn - the index of the child to returnJListgetAccessibleChildrenCount()