public class VizFileViewer extends org.eclipse.ui.part.ViewPart implements IVizUpdateableListener, org.eclipse.jface.viewers.ISelectionChangedListener
PlotEditor
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
ID
The ID for this view.
|
component
Constructor and Description |
---|
VizFileViewer()
The default constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
addFile(IResource resource)
Add an ICEResource to the VizFileViewer.
|
void |
createPartControl(org.eclipse.swt.widgets.Composite parent)
Creates the widgets and controls for the VizFileViewer.
|
VizResourceComponent |
getResourceComponent()
This operation retrieves the active ResourceComponent of this view or
null if the component does not exist.
|
void |
removeSelection()
Removes all ICEResources selected in
fileTreeViewer from the
ResourceComponent. |
void |
selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent event)
This listens for selection change events in the fileTreeViewer and
updates
deleteFileAction depending on whether or not a file is
selected. |
void |
setFocus()
Does nothing yet.
|
void |
setResourceComponent(VizResourceComponent component)
This operation sets the ResourceComponent that should be used by this
view.
|
void |
update(IVizUpdateable component)
Updates the VizFileViewer (specifically, the fileTreeViewer) when the
ResourceComponent is updated.
|
getViewSite, init, init, saveState, setInitializationData
addPartPropertyListener, addPropertyListener, dispose, getAdapter, getContentDescription, getOrientation, getPartName, getPartProperties, getPartProperty, getSite, getTitle, getTitleImage, getTitleToolTip, removePartPropertyListener, removePropertyListener, setPartProperty, showBusy
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
public static final java.lang.String ID
public void createPartControl(org.eclipse.swt.widgets.Composite parent)
fileTreeViewer
.createPartControl
in interface org.eclipse.ui.IWorkbenchPart
createPartControl
in class org.eclipse.ui.part.WorkbenchPart
parent
- The parent Composite that will contain this VizFileViewer.public void setFocus()
setFocus
in interface org.eclipse.ui.IWorkbenchPart
setFocus
in class org.eclipse.ui.part.WorkbenchPart
public void update(IVizUpdateable component)
update
in interface IVizUpdateableListener
component
- The ResourceComponent that was just updated.public void setResourceComponent(VizResourceComponent component)
component
- The ResourceComponentpublic VizResourceComponent getResourceComponent()
public void removeSelection()
fileTreeViewer
from the
ResourceComponent.public void addFile(IResource resource)
resource
- an ICEResource for the file to add to the VizFileViewer.public void selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent event)
deleteFileAction
depending on whether or not a file is
selected. Also, this method shows an appropriate plot viewer based on the
file type of the selection.selectionChanged
in interface org.eclipse.jface.viewers.ISelectionChangedListener
event
- The SelectionChangedEvent that fired this method.