Class ShowThumbnailAction

  • All Implemented Interfaces:
    java.awt.event.ActionListener, java.io.Serializable, java.lang.Cloneable, java.util.EventListener, javax.swing.Action, Layer.LayerAction

    public class ShowThumbnailAction
    extends javax.swing.AbstractAction
    implements Layer.LayerAction
    Toggle the image display between thumbnails and symbols.
    Since:
    7935
    See Also:
    Serialized Form
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private GeoImageLayer layer  
      • Fields inherited from class javax.swing.AbstractAction

        changeSupport, enabled
      • Fields inherited from interface javax.swing.Action

        ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void actionPerformed​(java.awt.event.ActionEvent e)
      This is called after the menu entry was selected.
      java.awt.Component createMenuComponent()
      Create actual menu entry and define if it is enabled or not.
      private static boolean enabled​(GeoImageLayer layer)
      Check if there is any suitable image to be toggled.
      boolean supportLayers​(java.util.List<Layer> layers)
      Check if the current layer is supported.
      • Methods inherited from class javax.swing.AbstractAction

        addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
      • Methods inherited from class java.lang.Object

        equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface javax.swing.Action

        accept
    • Constructor Detail

    • Method Detail

      • actionPerformed

        public void actionPerformed​(java.awt.event.ActionEvent e)
        This is called after the menu entry was selected.
        Specified by:
        actionPerformed in interface java.awt.event.ActionListener
        Parameters:
        e - action event
      • enabled

        private static boolean enabled​(GeoImageLayer layer)
        Check if there is any suitable image to be toggled.
        Parameters:
        layer - image layer
        Returns:
        true if there are images to be toggled, false otherwise
      • supportLayers

        public boolean supportLayers​(java.util.List<Layer> layers)
        Check if the current layer is supported.
        Specified by:
        supportLayers in interface Layer.LayerAction
        Parameters:
        layers - list of layers
        Returns:
        true if this action supports the given list of layers, false otherwise