ucar.unidata.idv.ui
Class ViewPanelImpl

java.lang.Object
  extended by ucar.unidata.ui.WindowHolder
      extended by ucar.unidata.idv.IdvManager
          extended by ucar.unidata.idv.ui.ViewPanelImpl
All Implemented Interfaces:
ActionListener, EventListener, IdvConstants, ViewPanel

public class ViewPanelImpl
extends IdvManager
implements ViewPanel

Manages the user interface for the IDV

Author:
IDV development team

Nested Class Summary
 class ViewPanelImpl.VMInfo
          Class VMInfo Holds gui stuff for a viewmanager
 
Field Summary
static Border headerPanelBorder
          The border for the header panel
static Border headerPanelHighlightBorder
          highlight border for view infos
static ImageIcon ICON_DEFAULT
          default icon
static ImageIcon ICON_GLOBE
          icon for globe views
static ImageIcon ICON_MAP
          icon for map views
static ImageIcon ICON_TRANSECT
          icon for transect views
 
Fields inherited from class ucar.unidata.ui.WindowHolder
dialog, frame, window
 
Fields inherited from interface ucar.unidata.idv.IdvConstants
ARG_B64BUNDLE, ARG_BUNDLE, ARG_CATALOG, ARG_CHOOSER, ARG_CLEARDEFAULT, ARG_CODE, ARG_CONNECT, ARG_CURRENTTIME, ARG_DATA, ARG_DEBUG, ARG_DEFAULT, ARG_DISPLAY, ARG_DXML, ARG_FIXEDTIME, ARG_HELP, ARG_IMAGE, ARG_IMAGESERVER, ARG_INSTALLPLUGIN, ARG_ISLFILE, ARG_ISLINTERACTIVE, ARG_LISTRESOURCES, ARG_MAINCLASS, ARG_MOVIE, ARG_MSG_DEBUG, ARG_MSG_RECORD, ARG_NODEFAULT, ARG_NOGUI, ARG_NOONEINSTANCE, ARG_NOPLUGINS, ARG_NOPREF, ARG_ONEINSTANCEPORT, ARG_PLUGIN, ARG_PORT, ARG_PRINTJNLP, ARG_PROPERTIES, ARG_SCRIPT, ARG_SERVER, ARG_SETFILES, ARG_SITEPATH, ARG_TEMPLATE, ARG_TEST, ARG_TESTEVAL, ARG_TRACE, ARG_TRACEONLY, ARG_USERPATH, DEFAULT_DATE_FORMAT, DEFAULT_DOCPATH, DEFAULT_TIMEZONE, FILE_VMSTATE, FILTER_CPT, FILTER_ISL, FILTER_JNLP, FILTER_XIDV, FILTER_XIDVZIDV, FILTER_XML, FILTER_ZIDV, ID_COMMANDSTORUN, ID_DATASOURCES, ID_DISPLAYCONTROLS, ID_IDV, ID_JYTHON, ID_MESSAGE, ID_MISCHASHTABLE, ID_VERSION, ID_VIEWMANAGERS, ID_WINDOWS, INITIAL_PROBE_EARTHLOCATION, NULL_DATA_SELECTION, NULL_STRING, PREF_ARCHIVEDIR, PREF_ARCHIVENAME, PREF_AUTODISPLAYS_ENABLE, PREF_AUTODISPLAYS_SHOWGUI, PREF_AUTOSELECTDATA, PREF_CACHESIZE, PREF_CONTROLSINTABS, PREF_DATAPREFIX, PREF_DATE_FORMAT, PREF_DISTANCEUNIT, PREF_DOCACHE, PREF_EMBEDDATACHOOSERINDASHBOARD, PREF_EMBEDFIELDSELECTORINDASHBOARD, PREF_EMBEDLEGENDINDASHBOARD, PREF_EMBEDQUICKLINKSINDASHBOARD, PREF_EVENT_KEYBOARDMAP, PREF_EVENT_MOUSEMAP, PREF_EVENT_WHEELMAP, PREF_FAST_RENDER, PREF_FIELD_CACHETHRESHOLD, PREF_FILEREADDIR, PREF_FILEWRITEDIR, PREF_HISTORY, PREF_LASTVERSION, PREF_LATLON_FORMAT, PREF_LOCALE, PREF_LOOKANDFEEL, PREF_MAXIMAGESIZE, PREF_OPEN_ASK, PREF_OPEN_MERGE, PREF_OPEN_REMOVE, PREF_PROJ_LIST, PREF_SAMPLINGMODE, PREF_SHOWCONTROLWINDOW, PREF_SHOWDASHBOARD, PREF_SHOWDECODEDIALOG, PREF_SHOWHIDDENFILES, PREF_SHOWQUITCONFIRM, PREF_SITEPATH, PREF_TIMEZONE, PREF_VERTICALCS, PREF_VERTICALUNIT, PREF_ZIDV_ASK, PREF_ZIDV_DIRECTORY, PREF_ZIDV_SAVETOTMP, PROP_3DMODE, PROP_ABOUTTEXT, PROP_APPRESOURCEPATH, PROP_CHOOSERS, PROP_CHOOSERS_ALL, PROP_CONTROLDESCRIPTORS, PROP_CONTROLDESCRIPTORS_ALL, PROP_DATAHOLDERBOUNDS, PROP_DEFAULTLOCATIONS, PROP_JNLPCODEBASE, PROP_JNLPTEMPLATE, PROP_JNLPTITLE, PROP_LOADINGXML, PROP_OLDCONTROLDESCRIPTORS, PROP_ONEINSTANCEPORT, PROP_PREFERENCES, PROP_PROJ_NAME, PROP_RESOURCEFILES, PROP_SHOWDASHBOARD, PROP_SHOWDATATREE, PROP_SHOWFORMULAS, PROP_SHOWSPLASH, PROP_SPLASHICON, PROP_UI_DESKTOP, PROP_VERSIONFILE, PROP_WINDOW_SCREENSIZEOFFSET, PROP_WINDOW_SIZEHEIGHT, PROP_WINDOW_SIZEWIDTH, PROP_WINDOW_USESCREENSIZE, SUFFIX_BAT, SUFFIX_CPT, SUFFIX_ISL, SUFFIX_JNLP, SUFFIX_RBI, SUFFIX_SH, SUFFIX_XIDV, SUFFIX_XML, SUFFIX_ZIDV
 
Constructor Summary
ViewPanelImpl(IntegratedDataViewer idv)
          Create me with the IDV
 
Method Summary
 void addDisplayControl(DisplayControl control)
          Add the given display control
 void addViewMenuItems(DisplayControl control, List items)
          Add view menu items for the display control
 void controlMoved(DisplayControl control)
          Handle a control moved
 void displayControlChanged(DisplayControl displayControl)
          Called by the IDV when there has been a change to the display controls.
 void dockControl(DisplayControl control)
          Reinserts the control into the control tabs
 void expandControl(DisplayControl control)
          Expand the control's gui in the tabs
 JComponent getContents()
          Make, if needed, and return the contents
protected static void initButtonState(IntegratedDataViewer idv)
          Initialize the button state
 void removeControlTab(DisplayControl control)
          Remove the control from the control tab if we are doing control tabs
 void removeDisplayControl(DisplayControl control)
           
 void undockControl(DisplayControl control)
          Remove the control from the tabs
 void viewManagerAdded(ViewManager viewManager)
          Be notified of the addition of a VM
 void viewManagerChanged(ViewManager viewManager)
          Called when the ViewManager is changed.
 void viewManagerDestroyed(ViewManager viewManager)
          Called when the ViewManager is removed.
 
Methods inherited from class ucar.unidata.idv.IdvManager
getArgsManager, getCollabManager, getColorTableManager, getDataManager, getIdv, getIdvChooserManager, getIdvClass, getIdvProjectionManager, getIdvUIManager, getImageGenerator, getJythonManager, getPersistenceManager, getPreferenceManager, getProperty, getProperty, getProperty, getPublishManager, getResourceManager, getStateManager, getStationModelManager, getStore, getVMManager, logException, showNormalCursor, showWaitCursor, waitUntilDisplaysAreDone
 
Methods inherited from class ucar.unidata.ui.WindowHolder
actionPerformed, close, doMakeContents, getDialog, getFrame, getWindow, getWindowTitle, isShowing, removeAll, setWindowTitle, shouldMakeDialog, show, show, showModal, toFront, windowIsClosing
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ICON_MAP

public static ImageIcon ICON_MAP
icon for map views


ICON_TRANSECT

public static ImageIcon ICON_TRANSECT
icon for transect views


ICON_GLOBE

public static ImageIcon ICON_GLOBE
icon for globe views


ICON_DEFAULT

public static ImageIcon ICON_DEFAULT
default icon


headerPanelBorder

public static Border headerPanelBorder
The border for the header panel


headerPanelHighlightBorder

public static Border headerPanelHighlightBorder
highlight border for view infos

Constructor Detail

ViewPanelImpl

public ViewPanelImpl(IntegratedDataViewer idv)
Create me with the IDV

Parameters:
idv - The IDV
Method Detail

getContents

public JComponent getContents()
Make, if needed, and return the contents

Specified by:
getContents in interface ViewPanel
Overrides:
getContents in class WindowHolder
Returns:
the gui contents

addDisplayControl

public void addDisplayControl(DisplayControl control)
Add the given display control

Specified by:
addDisplayControl in interface ViewPanel
Parameters:
control - display control

viewManagerAdded

public void viewManagerAdded(ViewManager viewManager)
Be notified of the addition of a VM

Specified by:
viewManagerAdded in interface ViewPanel
Parameters:
viewManager - The VM

viewManagerDestroyed

public void viewManagerDestroyed(ViewManager viewManager)
Called when the ViewManager is removed. If we are showing legends in a separate window then we remove the tab

Specified by:
viewManagerDestroyed in interface ViewPanel
Parameters:
viewManager - The ViewManager that was destroyed

viewManagerChanged

public void viewManagerChanged(ViewManager viewManager)
Called when the ViewManager is changed. If we are showing legends in a separate window then we update the tab label

Specified by:
viewManagerChanged in interface ViewPanel
Parameters:
viewManager - The ViewManager that was changed

displayControlChanged

public void displayControlChanged(DisplayControl displayControl)
Called by the IDV when there has been a change to the display controls.

Specified by:
displayControlChanged in interface ViewPanel
Parameters:
displayControl - The control that changed

removeDisplayControl

public void removeDisplayControl(DisplayControl control)
Specified by:
removeDisplayControl in interface ViewPanel
Parameters:
control - The removed control

removeControlTab

public void removeControlTab(DisplayControl control)
Remove the control from the control tab if we are doing control tabs

Parameters:
control - The control

addViewMenuItems

public void addViewMenuItems(DisplayControl control,
                             List items)
Add view menu items for the display control

Specified by:
addViewMenuItems in interface ViewPanel
Parameters:
control - the display control
items - List of menu items

expandControl

public void expandControl(DisplayControl control)
Expand the control's gui in the tabs

Parameters:
control - The control

dockControl

public void dockControl(DisplayControl control)
Reinserts the control into the control tabs

Parameters:
control - the control

undockControl

public void undockControl(DisplayControl control)
Remove the control from the tabs

Parameters:
control - The control

controlMoved

public void controlMoved(DisplayControl control)
Handle a control moved

Specified by:
controlMoved in interface ViewPanel
Parameters:
control - the moved control

initButtonState

protected static void initButtonState(IntegratedDataViewer idv)
Initialize the button state

Parameters:
idv - the idv