|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavax.swing.AbstractAction
org.jminor.common.ui.control.Control
org.jminor.common.ui.control.ControlSet
public final class ControlSet
A set of Actions/Controls, includes separators.
Field Summary |
---|
Fields inherited from class javax.swing.AbstractAction |
---|
changeSupport, enabled |
Fields inherited from interface javax.swing.Action |
---|
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON |
Constructor Summary | |
---|---|
ControlSet()
Constructs a new ControlSet. |
|
ControlSet(Control... controls)
Constructs a new ControlSet |
|
ControlSet(String name)
Constructs a new ControlSet |
|
ControlSet(String name,
char mnemonic)
Constructs a new ControlSet |
|
ControlSet(String name,
char mnemonic,
Control... controls)
Constructs a new ControlSet |
|
ControlSet(String name,
char mnemonic,
ImageIcon icon)
Constructs a new ControlSet |
|
ControlSet(String name,
char mnemonic,
ImageIcon icon,
StateObserver enabledState)
Constructs a new ControlSet |
|
ControlSet(String name,
char mnemonic,
State enabledState,
Control... controls)
Constructs a new ControlSet |
|
ControlSet(String name,
char mnemonic,
State enabledState,
ImageIcon icon,
Control... controls)
Constructs a new ControlSet |
|
ControlSet(String name,
Control... controls)
Constructs a new ControlSet |
Method Summary | |
---|---|
void |
add(Action action)
Adds the given action to this ControlSet, adding a null action has the same effect as addSeparator() |
void |
add(ControlSet controlSet)
|
void |
addAll(ControlSet controlSet)
Adds all action found in controlSet to this control set |
void |
addAt(Action action,
int index)
Adds the given action to this ControlSet at the specified index, adding a null action has the same effect as addSeparator() |
void |
addAt(ControlSet controlSet,
int index)
|
void |
addSeparator()
Adds a separator to this control set |
void |
addSeparatorAt(int index)
Adds a separator at the given index |
Action |
get(int index)
|
List<Action> |
getActions()
|
List<ControlSet> |
getControlSets()
|
boolean |
hasIcon()
|
boolean |
hasName()
|
boolean |
remove(Action action)
|
boolean |
remove(ControlSet controlSet)
|
void |
removeAll()
Removes all actions from this control set |
int |
size()
|
Methods inherited from class org.jminor.common.ui.control.Control |
---|
actionPerformed, getDescription, getEnabledState, getIcon, getMnemonic, getName, isEnabled, setDescription, setEnabled, setIcon, setKeyStroke, setMnemonic, setName |
Methods inherited from class javax.swing.AbstractAction |
---|
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, putValue, removePropertyChangeListener |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ControlSet()
public ControlSet(String name)
name
- the control set namepublic ControlSet(String name, char mnemonic)
name
- the control set namemnemonic
- the mnemonic to assign to this control setpublic ControlSet(String name, char mnemonic, ImageIcon icon)
name
- the control set namemnemonic
- the mnemonic to assign to this control seticon
- the iconpublic ControlSet(String name, char mnemonic, ImageIcon icon, StateObserver enabledState)
name
- the control set namemnemonic
- the mnemonic to assign to this control seticon
- the iconenabledState
- the state observer dictating the enable state of this controlpublic ControlSet(Control... controls)
controls
- the controls to add to this setpublic ControlSet(String name, Control... controls)
name
- the control set namecontrols
- the controls to add to this setpublic ControlSet(String name, char mnemonic, Control... controls)
name
- the control set namemnemonic
- the mnemonic to assign to this control setcontrols
- the controls to add to this setpublic ControlSet(String name, char mnemonic, State enabledState, Control... controls)
name
- the control set namemnemonic
- the mnemonic to assign to this control setenabledState
- the state observer dictating the enable state of this controlcontrols
- the controls to add to this setpublic ControlSet(String name, char mnemonic, State enabledState, ImageIcon icon, Control... controls)
name
- the control set namemnemonic
- the mnemonic to assign to this control setenabledState
- the state observer dictating the enable state of this controlicon
- the iconcontrols
- the controls to add to this setMethod Detail |
---|
public List<ControlSet> getControlSets()
public List<Action> getActions()
public void add(Action action)
action
- the action to addpublic void addAt(Action action, int index)
action
- the action to add at the specified indexindex
- the indexpublic boolean remove(Action action)
action
- the action to remove
public boolean remove(ControlSet controlSet)
controlSet
- the control set to remove
public void removeAll()
public int size()
public Action get(int index)
index
- the index
public void add(ControlSet controlSet)
controlSet
- the control set to addpublic void addAt(ControlSet controlSet, int index)
controlSet
- the control set to add at the specified indexindex
- the indexpublic void addSeparator()
public void addSeparatorAt(int index)
index
- the indexpublic boolean hasName()
public boolean hasIcon()
public void addAll(ControlSet controlSet)
controlSet
to this control set
controlSet
- the source set
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |