static class MainMenu.PresetsMenuEnabler extends Object implements MapView.LayerChangeListener
Modifier and Type | Field and Description |
---|---|
private JMenu |
presetsMenu |
Constructor and Description |
---|
MainMenu.PresetsMenuEnabler(JMenu presetsMenu) |
Modifier and Type | Method and Description |
---|---|
void |
activeLayerChange(Layer oldLayer,
Layer newLayer)
Notifies this listener that the active layer has changed.
|
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.
|
protected void |
refreshEnabled()
Refreshes the enabled state
|
private JMenu presetsMenu
public MainMenu.PresetsMenuEnabler(JMenu presetsMenu)
protected void refreshEnabled()
public void activeLayerChange(Layer oldLayer, Layer newLayer)
MapView.LayerChangeListener
activeLayerChange
in interface MapView.LayerChangeListener
oldLayer
- The previous active layernewLayer
- The new activer layerpublic void layerAdded(Layer newLayer)
MapView.LayerChangeListener
layerAdded
in interface MapView.LayerChangeListener
newLayer
- The new added layerpublic void layerRemoved(Layer oldLayer)
MapView.LayerChangeListener
layerRemoved
in interface MapView.LayerChangeListener
oldLayer
- The old removed layer