Class ChooseTrackVisibilityAction

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

    public class ChooseTrackVisibilityAction
    extends javax.swing.AbstractAction
    allows the user to choose which of the downloaded tracks should be displayed. they can be chosen from the gpx layer context menu.
    See Also:
    Serialized Form
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private DateFilterPanel dateFilter  
      private GpxLayer layer  
      private boolean noUpdates  
      private javax.swing.JTable table  
      • 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 ae)  
      private static javax.swing.JTable buildTable​(java.lang.Object[]... content)
      Builds an editable table whose 5th column will open a browser when double clicked.
      private java.lang.Object[][] buildTableContents()
      Gathers all available data for the tracks and returns them as array of arrays in the expected column order.
      private void listenToSelectionChanges()
      listens to selection changes in the table and redraws the map
      private void selectVisibleTracksInTable()
      selects all rows (=tracks) in the table that are currently visible on the layer
      private void showColorDialog​(java.util.List<IGpxTrack> tracks)  
      private void updateVisibilityFromTable()  
      • 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

      • ChooseTrackVisibilityAction

        public ChooseTrackVisibilityAction​(GpxLayer layer)
        Constructs a new ChooseTrackVisibilityAction.
        Parameters:
        layer - The associated GPX layer
    • Method Detail

      • buildTableContents

        private java.lang.Object[][] buildTableContents()
        Gathers all available data for the tracks and returns them as array of arrays in the expected column order.
        Returns:
        table data
      • buildTable

        private static javax.swing.JTable buildTable​(java.lang.Object[]... content)
        Builds an editable table whose 5th column will open a browser when double clicked. The table will fill its parent.
        Parameters:
        content - table data
        Returns:
        non-editable table
      • selectVisibleTracksInTable

        private void selectVisibleTracksInTable()
        selects all rows (=tracks) in the table that are currently visible on the layer
      • listenToSelectionChanges

        private void listenToSelectionChanges()
        listens to selection changes in the table and redraws the map
      • actionPerformed

        public void actionPerformed​(java.awt.event.ActionEvent ae)