public final class ActivateLayerAction extends javax.swing.AbstractAction implements IEnabledStateUpdating, MapView.LayerChangeListener, MultikeyShortcutAction
MultikeyShortcutAction.MultikeyInfo| Modifier and Type | Field and Description |
|---|---|
private Layer |
layer |
private LayerListDialog.LayerListModel |
model |
private Shortcut |
multikeyShortcut |
| Constructor and Description |
|---|
ActivateLayerAction(Layer layer,
LayerListDialog.LayerListModel model)
Constructs a new
ActivateLayerAction. |
ActivateLayerAction(LayerListDialog.LayerListModel model)
Constructs a new
ActivateLayerAction. |
| Modifier and Type | Method and Description |
|---|---|
void |
actionPerformed(java.awt.event.ActionEvent e) |
void |
activeLayerChange(Layer oldLayer,
Layer newLayer)
Notifies this listener that the active layer has changed.
|
private void |
execute(Layer layer) |
void |
executeMultikeyAction(int index,
boolean repeat) |
MultikeyShortcutAction.MultikeyInfo |
getLastMultikeyAction() |
java.util.List<MultikeyShortcutAction.MultikeyInfo> |
getMultikeyCombinations() |
Shortcut |
getMultikeyShortcut() |
protected boolean |
isActiveLayer(Layer layer) |
void |
layerAdded(Layer newLayer)
Notifies this listener that a layer has been added.
|
void |
layerRemoved(Layer oldLayer)
Notifies this listener that a layer has been removed.
|
void |
updateEnabledState()
Called after the layer model has changed.
|
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabledprivate transient Shortcut multikeyShortcut
private final LayerListDialog.LayerListModel model
public ActivateLayerAction(Layer layer, LayerListDialog.LayerListModel model)
ActivateLayerAction.layer - the layermodel - layer list modelpublic ActivateLayerAction(LayerListDialog.LayerListModel model)
ActivateLayerAction.model - layer list modelpublic Shortcut getMultikeyShortcut()
getMultikeyShortcut in interface MultikeyShortcutActionpublic void actionPerformed(java.awt.event.ActionEvent e)
actionPerformed in interface java.awt.event.ActionListenerprotected boolean isActiveLayer(Layer layer)
public void updateEnabledState()
IEnabledStateUpdatingupdateEnabledState in interface IEnabledStateUpdatingpublic void activeLayerChange(Layer oldLayer, Layer newLayer)
MapView.LayerChangeListeneractiveLayerChange in interface MapView.LayerChangeListeneroldLayer - The previous active layernewLayer - The new activer layerpublic void layerAdded(Layer newLayer)
MapView.LayerChangeListenerlayerAdded in interface MapView.LayerChangeListenernewLayer - The new added layerpublic void layerRemoved(Layer oldLayer)
MapView.LayerChangeListenerlayerRemoved in interface MapView.LayerChangeListeneroldLayer - The old removed layerpublic void executeMultikeyAction(int index, boolean repeat)
executeMultikeyAction in interface MultikeyShortcutActionpublic java.util.List<MultikeyShortcutAction.MultikeyInfo> getMultikeyCombinations()
getMultikeyCombinations in interface MultikeyShortcutActionpublic MultikeyShortcutAction.MultikeyInfo getLastMultikeyAction()
getLastMultikeyAction in interface MultikeyShortcutAction