com.sshtools.common.ui
Class ColorComboBox.ColorComboModel
java.lang.Object
javax.swing.AbstractListModel
com.sshtools.common.ui.ColorComboBox.ColorComboModel
- All Implemented Interfaces:
- java.io.Serializable, javax.swing.ComboBoxModel, javax.swing.ListModel
- Enclosing class:
- ColorComboBox
static class ColorComboBox.ColorComboModel
- extends javax.swing.AbstractListModel
- implements javax.swing.ComboBoxModel
Field Summary |
private java.util.Vector |
colors
|
private java.lang.Object |
selected
|
Fields inherited from class javax.swing.AbstractListModel |
listenerList |
Methods inherited from class javax.swing.AbstractListModel |
addListDataListener, fireContentsChanged, fireIntervalAdded, fireIntervalRemoved, getListDataListeners, getListeners, removeListDataListener |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface javax.swing.ListModel |
addListDataListener, removeListDataListener |
colors
private java.util.Vector colors
selected
private java.lang.Object selected
ColorComboBox.ColorComboModel
ColorComboBox.ColorComboModel()
getSize
public int getSize()
- Specified by:
getSize
in interface javax.swing.ListModel
getElementAt
public java.lang.Object getElementAt(int i)
- Specified by:
getElementAt
in interface javax.swing.ListModel
setSelectedItem
public void setSelectedItem(java.lang.Object sel)
- Specified by:
setSelectedItem
in interface javax.swing.ComboBoxModel
getSelectedItem
public java.lang.Object getSelectedItem()
- Specified by:
getSelectedItem
in interface javax.swing.ComboBoxModel
addColor
public void addColor(java.awt.Color c)