public final class LayerListDialog.MergeAction extends javax.swing.AbstractAction implements LayerListDialog.IEnabledStateUpdating, Layer.LayerAction, Layer.MultiLayerAction
| Modifier and Type | Field and Description |
|---|---|
private Layer |
layer |
private java.util.List<Layer> |
layers |
| Modifier | Constructor and Description |
|---|---|
|
MergeAction(Layer layer)
Constructs a new
MergeAction. |
private |
MergeAction(Layer layer,
java.util.List<Layer> layers)
Constructs a new
MergeAction. |
|
MergeAction(java.util.List<Layer> layers)
Constructs a new
MergeAction. |
| Modifier and Type | Method and Description |
|---|---|
void |
actionPerformed(java.awt.event.ActionEvent e) |
java.awt.Component |
createMenuComponent()
Creates and return the menu component.
|
LayerListDialog.MergeAction |
getMultiLayerAction(java.util.List<Layer> layers)
Returns the action for a given list of layers.
|
boolean |
supportLayers(java.util.List<Layer> layers)
Determines if this action supports a given list of layers.
|
void |
updateEnabledState() |
public MergeAction(Layer layer)
MergeAction.layer - the layerjava.lang.IllegalArgumentException - if layer is nullpublic MergeAction(java.util.List<Layer> layers)
MergeAction.layers - the layer listjava.lang.IllegalArgumentException - if layers is nullprivate MergeAction(Layer layer, java.util.List<Layer> layers)
MergeAction.layer - the layer (null if layer list if specified)layers - the layer list (null if a single layer is specified)public void actionPerformed(java.awt.event.ActionEvent e)
actionPerformed in interface java.awt.event.ActionListenerpublic void updateEnabledState()
updateEnabledState in interface LayerListDialog.IEnabledStateUpdatingpublic boolean supportLayers(java.util.List<Layer> layers)
Layer.LayerActionsupportLayers in interface Layer.LayerActionlayers - list of layerstrue if this action supports the given list of layers, false otherwisepublic java.awt.Component createMenuComponent()
Layer.LayerActioncreateMenuComponent in interface Layer.LayerActionpublic LayerListDialog.MergeAction getMultiLayerAction(java.util.List<Layer> layers)
Layer.MultiLayerActiongetMultiLayerAction in interface Layer.MultiLayerActionlayers - list of layers