public class AbstractFeature extends AbstractAction implements Feature
Modifier and Type | Field and Description |
---|---|
protected Controller |
controller |
protected String |
featureID |
changeSupport, enabled
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Modifier | Constructor and Description |
---|---|
protected |
AbstractFeature(String s,
String featureID,
Registry registry) |
protected |
AbstractFeature(String s,
String featureID,
String largeIconPath,
Registry registry) |
Modifier and Type | Method and Description |
---|---|
void |
actionPerformed(ActionEvent actionEvent) |
protected void |
addToToolBar() |
protected void |
doActionPerformed(ActionEvent actionEvent) |
void |
doPropertyChange(PropertyChangeEvent propertyChangeEvent) |
Controller |
getController() |
String |
getFeatureID() |
String |
getName() |
String |
getStringValue(String key) |
void |
initialize(Controller controller) |
boolean |
isInitialized() |
boolean |
isOn() |
boolean |
isTwoState()
Indicates whether the feature can be either on or off, without any other states.
|
void |
propertyChange(PropertyChangeEvent propertyChangeEvent) |
protected Object |
register(String featureID,
Registry registry) |
protected void |
setMenuAccellerator(Controller controller) |
void |
turnOn(boolean tf) |
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
addPropertyChangeListener, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
protected Controller controller
protected String featureID
public void actionPerformed(ActionEvent actionEvent)
actionPerformed
in interface ActionListener
protected void addToToolBar()
protected void doActionPerformed(ActionEvent actionEvent)
public void doPropertyChange(PropertyChangeEvent propertyChangeEvent)
public Controller getController()
public String getFeatureID()
getFeatureID
in interface Feature
public void initialize(Controller controller)
initialize
in interface Initializable
public boolean isInitialized()
isInitialized
in interface Initializable
public boolean isTwoState()
Feature
isTwoState
in interface Feature
public void propertyChange(PropertyChangeEvent propertyChangeEvent)
propertyChange
in interface PropertyChangeListener
protected void setMenuAccellerator(Controller controller)