Class OptionsDialog

All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible, RootPaneContainer, WindowConstants

public class OptionsDialog extends JDialog
A dialog for displaying user preferences. TODO: use JOptionPane.
See Also:
  • Constructor Details

    • OptionsDialog

      public OptionsDialog(Frame pOwner, Map<Preferences,OptionsPanel> pPrefToPanelMap)
      If only one options panel is passed, forget tabs. Otherwise, give each panel a tab.
      Parameters:
      pPrefToPanelMap - Map from Preferences to OptionsPanel
  • Method Details

    • getPrefToPanelMap

      public Map<Preferences,OptionsPanel> getPrefToPanelMap()
    • getOkAction

      protected Action getOkAction()
      Can be disabled when dialogs are in an invalid state.
    • commitChanges

      protected void commitChanges()
      Commits models to preferences. Order of commitment is defined by pref to panel map. Called after 'ok' is clicked. Override this method if special actions must be taken after (or in place of) the standard commit. Overriding methods that merely seek to display a message should call super.