public abstract class DisplayComponent extends PropertiedThing implements java.beans.PropertyChangeListener
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
CMD_SAVEIMAGE
Action command to save an image_
|
static java.lang.String |
CMD_SAVEMOVIE
Action command to save an moveie
|
protected MultiDisplayHolder |
displayControl
The displaycontrol I'm in
|
protected javax.swing.JLabel |
displayLabel
The label
|
protected boolean |
hasBeenInitialized
Has this component been initialized
|
boolean |
isRemoved
Has this component been removed
|
static java.lang.String |
PROP_REMOVED
Property change id
|
propertiesDialog
Constructor and Description |
---|
DisplayComponent()
default ctor
|
DisplayComponent(java.lang.String name)
ctor
|
Modifier and Type | Method and Description |
---|---|
protected java.util.List |
addGroupMenuItems(java.util.List items)
Add the parent group's menu items
|
void |
animationTimeChanged(visad.Real time)
Set animation time on components
|
protected boolean |
applyProperties()
Apply properties
|
protected boolean |
doApplyProperties()
Apply the properties
|
protected abstract javax.swing.JComponent |
doMakeContents()
Make the gui
|
protected javax.swing.JLabel |
doMakeDisplayLabel()
Create, if needed, and return the component label
|
void |
doRemove()
Been removed, do any cleanup
|
void |
doSaveImage()
Write the image
|
void |
doSaveMovie()
Create a movie
|
java.awt.Color |
getBackgroundColor()
Get the BackgroundColor property.
|
javax.swing.JComponent |
getContents()
Create, if needed, and return the gui contents
|
java.util.List |
getDisplayables()
Get the list of displayables
|
protected MultiDisplayHolder |
getDisplayControl()
Get the display control I'm in
|
DisplayGroup |
getDisplayGroup()
Get the DisplayGroup property.
|
protected javax.swing.JLabel |
getDisplayLabel()
Create, if needed, and return the component label
|
boolean |
getIsRemoved()
Get the IsRemoved property.
|
boolean |
getLabelShown()
Get the LabelShown property.
|
java.lang.String |
getName()
Get the Name property.
|
protected java.util.List |
getPopupMenuItems(java.util.List items)
Get the menu items for the popup menu
|
protected void |
getPropertiesComponents(java.util.List comps,
int tabIdx)
Create the properties contents
|
java.lang.String |
getTypeName()
Return the human readable name of this component
|
void |
initAfterUnPersistence(MultiDisplayHolder displayControl,
ControlContext vc,
java.util.Hashtable properties)
Called by the
IntegratedDataViewer to
initialize after this control has been unpersisted |
void |
initDone()
Finish with initialization
|
void |
loadData()
Tell components to load
|
boolean |
removeDisplayComponent()
Remove me
|
void |
setBackgroundColor(java.awt.Color value)
Set the BackgroundColor property.
|
void |
setDisplayControl(MultiDisplayHolder displayControl)
Set the display control I'm in
|
void |
setDisplayGroup(DisplayGroup value)
Set the DisplayGroup property.
|
void |
setIsRemoved(boolean value)
Set the IsRemoved property.
|
void |
setLabelShown(boolean value)
Set the LabelShown property.
|
void |
setName(java.lang.String value)
Set the Name property.
|
void |
showPopup(javax.swing.JComponent where,
int x,
int y)
SHow the popup menu
|
boolean |
showProperties()
Show the properties dialog
|
java.lang.String |
toString()
to string
|
addPropertyChangeListener, firePropertyChange, firePropertyChange, getPropertyListeners, getPropertyTabs, isShowing, propertyChange, removePropertyChangeListener, showProperties
applySharableProperties, doShare, doShare, doShareExternal, doShareInternal, getReceiveShareTime, getSharablePropertiesComponent, getShareGroup, getSharing, getUniqueId, initSharable, receiveShareData, removeSharable, setReceiveShareTime, setShareGroup, setSharing, setUniqueId, showSharableDialog
public static final java.lang.String PROP_REMOVED
public boolean isRemoved
protected boolean hasBeenInitialized
public static final java.lang.String CMD_SAVEIMAGE
public static final java.lang.String CMD_SAVEMOVIE
protected javax.swing.JLabel displayLabel
protected MultiDisplayHolder displayControl
public DisplayComponent()
public DisplayComponent(java.lang.String name)
name
- namepublic void initDone()
public void initAfterUnPersistence(MultiDisplayHolder displayControl, ControlContext vc, java.util.Hashtable properties)
IntegratedDataViewer
to
initialize after this control has been unpersisteddisplayControl
- The display control I am part ofvc
- The context in which this control existsproperties
- Properties that may hold thingsprotected abstract javax.swing.JComponent doMakeContents()
public javax.swing.JComponent getContents()
public void setDisplayControl(MultiDisplayHolder displayControl)
displayControl
- The display controlprotected MultiDisplayHolder getDisplayControl()
public void animationTimeChanged(visad.Real time)
time
- timepublic void loadData() throws java.rmi.RemoteException, visad.VisADException
java.rmi.RemoteException
- On badnessvisad.VisADException
- On badnesspublic void doSaveMovie()
public void doSaveImage()
protected java.util.List addGroupMenuItems(java.util.List items)
items
- menu itemspublic java.util.List getDisplayables()
public boolean removeDisplayComponent()
protected boolean doApplyProperties()
doApplyProperties
in class PropertiedThing
public void doRemove()
public void setName(java.lang.String value)
value
- The new value for Namepublic java.lang.String getName()
public void setDisplayGroup(DisplayGroup value)
value
- The new value for DisplayGrouppublic DisplayGroup getDisplayGroup()
public java.lang.String toString()
toString
in class java.lang.Object
public void setBackgroundColor(java.awt.Color value)
value
- The new value for BackgroundColorpublic java.awt.Color getBackgroundColor()
public java.lang.String getTypeName()
protected void getPropertiesComponents(java.util.List comps, int tabIdx)
getPropertiesComponents
in class PropertiedThing
comps
- List of componentstabIdx
- Which tabprotected boolean applyProperties()
applyProperties
in class PropertiedThing
protected java.util.List getPopupMenuItems(java.util.List items)
items
- List of items to add topublic boolean showProperties()
showProperties
in class PropertiedThing
public void showPopup(javax.swing.JComponent where, int x, int y)
where
- component to show near tox
- xy
- yprotected javax.swing.JLabel getDisplayLabel()
protected javax.swing.JLabel doMakeDisplayLabel()
public void setLabelShown(boolean value)
value
- The new value for LabelShownpublic boolean getLabelShown()
public void setIsRemoved(boolean value)
value
- The new value for IsRemovedpublic boolean getIsRemoved()