public class SidePaneGroup extends java.util.ArrayList<SidePaneItem>
SidePane
to represent a group of SidePaneItem
.
Each group usually has one SidePaneItem
selected.Modifier and Type | Field and Description |
---|---|
protected javax.swing.event.EventListenerList |
listenerList
A list of event listeners for this component.
|
Constructor and Description |
---|
SidePaneGroup()
Default constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
addSidePaneListener(SidePaneListener l)
Adds the specified listener to receive side pane events from this side pane group.
|
boolean |
exists(java.awt.Component comp)
Checks if the component exists in this group.
|
protected void |
fireSidePaneEvent(SidePaneItem sidePaneItem,
int id)
Fires a side pane event.
|
java.lang.String |
getLongestTitle()
Get longest title in this group.
|
int |
getSelectedIndex()
Gets the selected index.
|
SidePaneItem |
getSelectedItem()
Gets the selected item.
|
SidePaneItem |
getSidePaneItem(java.awt.Component comp)
Checks if the component exists in this group.
|
SidePaneListener[] |
getSidePaneListeners()
Returns an array of all the
SidePaneListener s added to this
SidePaneGroup with addSidePaneListener . |
boolean |
removeComponent(java.awt.Component comp)
Removes the component from this group.
|
void |
removeSidePaneListener(SidePaneListener l)
Removes the specified side pane listener so that it no longer receives side pane events from
this side pane group.
|
void |
setSelectedIndex(int index)
Sets the selected index.
|
void |
setSelectedItem(SidePaneItem selectedItem)
Sets the selected item.
|
add, add, addAll, addAll, clear, clone, contains, ensureCapacity, forEach, get, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, removeIf, removeRange, replaceAll, retainAll, set, size, sort, spliterator, subList, toArray, toArray, trimToSize
protected javax.swing.event.EventListenerList listenerList
public SidePaneItem getSelectedItem()
public void setSelectedItem(SidePaneItem selectedItem)
selectedItem
- the item to be selectedpublic int getSelectedIndex()
public void setSelectedIndex(int index)
index
- the index of the item to be selectedpublic java.lang.String getLongestTitle()
public boolean removeComponent(java.awt.Component comp)
comp
- component to be removedtrue
if the component is removedpublic boolean exists(java.awt.Component comp)
comp
- component to be checkedtrue
if the component existspublic SidePaneItem getSidePaneItem(java.awt.Component comp)
comp
- component to be checkedtrue
if the component existspublic void addSidePaneListener(SidePaneListener l)
l
- the side pane listenerpublic void removeSidePaneListener(SidePaneListener l)
l
- the dockable frame listenerpublic SidePaneListener[] getSidePaneListeners()
SidePaneListener
s added to this
SidePaneGroup
with addSidePaneListener
.SidePaneListener
s added or an empty array if no listeners
have been addedaddSidePaneListener(com.jidesoft.swing.event.SidePaneListener)
protected void fireSidePaneEvent(SidePaneItem sidePaneItem, int id)
sidePaneItem
- the event sourceid
- the type of the event being fired; one of the following: If the event
type is not one of the above, nothing happens.