ucar.unidata.idv.control
Class DisplaySettingsDialog

java.lang.Object
  extended by ucar.unidata.idv.control.DisplaySettingsDialog

public class DisplaySettingsDialog
extends Object

Shows the display settings dialog

Version:
$Revision: 1.13 $
Author:
IDV development team

Nested Class Summary
 class DisplaySettingsDialog.PropertyValueWrapper
          Class PropertyValueWrapper utility class
 
Constructor Summary
DisplaySettingsDialog(DisplayControlImpl display)
          ctor
DisplaySettingsDialog(IntegratedDataViewer idv)
          ctor
DisplaySettingsDialog(IntegratedDataViewer idv, DisplayControlImpl display)
          ctor
DisplaySettingsDialog(IntegratedDataViewer idv, DisplayControlImpl display, boolean showDialog)
          The ctor
 
Method Summary
protected  void addPropertyValue(Object object, String propName, String label, String category)
          Add a property value
 void applyDisplaySetting(DisplaySetting displaySetting)
          Apply the display settings
 void doApply()
          apply dialog
 void doCancel()
          cancel dialog
 void doOk()
          do ok of dialog
 void doSave()
          Save the settings
 List<PropertyValue> getPropertyValues()
          Get the property values
static String getValueLabel(Object v)
          Get label to show for the given value
static List makeDisplaySettingsMenuItems(List<DisplaySetting> displaySettings, Object object, String method, String labelPrefix)
          make menu items
 void setDisplay(DisplayControlImpl display)
          Set the display to use
 void showSelectMenu(JMenu menu)
          Add items to the Select menu
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DisplaySettingsDialog

public DisplaySettingsDialog(IntegratedDataViewer idv,
                             DisplayControlImpl display)
ctor

Parameters:
idv - the idv
display - The initial display to use

DisplaySettingsDialog

public DisplaySettingsDialog(IntegratedDataViewer idv,
                             DisplayControlImpl display,
                             boolean showDialog)
The ctor

Parameters:
idv - the idv
display - Initial display to use
showDialog - Should we show the dialog

DisplaySettingsDialog

public DisplaySettingsDialog(IntegratedDataViewer idv)
ctor

Parameters:
idv - the idv

DisplaySettingsDialog

public DisplaySettingsDialog(DisplayControlImpl display)
ctor

Parameters:
display - The initial display
Method Detail

getPropertyValues

public List<PropertyValue> getPropertyValues()
Get the property values

Returns:
property values

setDisplay

public void setDisplay(DisplayControlImpl display)
Set the display to use

Parameters:
display - The display

addPropertyValue

protected void addPropertyValue(Object object,
                                String propName,
                                String label,
                                String category)
Add a property value

Parameters:
object - value of the property
propName - its name
label - label to use
category - The category of the property

showSelectMenu

public void showSelectMenu(JMenu menu)
Add items to the Select menu

Parameters:
menu - select menu

doSave

public void doSave()
Save the settings


applyDisplaySetting

public void applyDisplaySetting(DisplaySetting displaySetting)
Apply the display settings

Parameters:
displaySetting - The display setting

makeDisplaySettingsMenuItems

public static List makeDisplaySettingsMenuItems(List<DisplaySetting> displaySettings,
                                                Object object,
                                                String method,
                                                String labelPrefix)
make menu items

Parameters:
displaySettings - List of display settings
object - ???
method - Method to call
labelPrefix - Prefix
Returns:
Items

doCancel

public void doCancel()
cancel dialog


doOk

public void doOk()
do ok of dialog


doApply

public void doApply()
apply dialog


getValueLabel

public static String getValueLabel(Object v)
Get label to show for the given value

Parameters:
v - value
Returns:
label