Class BundleChooser

All Implemented Interfaces:
ActionListener, ImageObserver, MenuContainer, Serializable, EventListener, Accessible, IdvConstants

public class BundleChooser extends IdvChooser
A chooser that shows the SavedBundles from the bundles.xml
Author:
IDV development team
See Also:
  • Constructor Details

    • BundleChooser

      public BundleChooser(IdvChooserManager mgr, Element root)
      Create the BundleChooser, passing in the manager and the xml element from choosers.xml
      Parameters:
      mgr - The manager
      root - The xml root
  • Method Details

    • doMakeContents

      protected JComponent doMakeContents()
      Create the GUI for this chooser
      Overrides:
      doMakeContents in class ChooserPanel
      Returns:
      The gui of this chooser
    • doUpdate

      public void doUpdate()
      Reload the jtree
      Overrides:
      doUpdate in class ChooserPanel
    • doLoadInThread

      public void doLoadInThread()
      If a bundle is selected then load it in and close the chooser.
      Overrides:
      doLoadInThread in class ChooserPanel
    • loadBundle

      public void loadBundle(SavedBundle bundle)
      Load in the given bundle and, if successful, close the chooser
      Parameters:
      bundle - The bundle to load
    • getBundleAtPath

      protected SavedBundle getBundleAtPath(TreePath path)
      Find the SavedBundle associated with the given tree path
      Parameters:
      path - The path
      Returns:
      The saved bundle object or null.
    • treeClick

      protected void treeClick(MouseEvent event)
      Handle the tree click event
      Parameters:
      event - The event
    • getLoadCommandName

      public String getLoadCommandName()
      Overwrite base class method to return a different name for the load button
      Overrides:
      getLoadCommandName in class ChooserPanel
      Returns:
      Load button name