|
Eclipse Platform Release 3.0 | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.eclipse.swt.widgets.Widget
org.eclipse.swt.widgets.Control
org.eclipse.swt.widgets.Scrollable
org.eclipse.swt.widgets.Composite
org.eclipse.swt.custom.ViewForm
org.eclipse.compare.CompareViewerPane
org.eclipse.compare.CompareViewerSwitchingPane
A custom CompareViewerPane that supports dynamic viewer switching.
Clients must implement the viewer switching strategy by implementing the getViewer(Viewer, Object) method.
If a property with the name CompareUI.COMPARE_VIEWER_TITLE is set on the top level SWT control of a viewer, it is used as a title in the CompareViewerPane's title bar.
Field Summary |
Fields inherited from class org.eclipse.swt.custom.ViewForm |
borderInsideRGB, borderMiddleRGB, borderOutsideRGB, horizontalSpacing, marginHeight, marginWidth, verticalSpacing |
Fields inherited from class org.eclipse.swt.widgets.Control |
handle |
Constructor Summary | |
CompareViewerSwitchingPane(Composite parent,
int style)
Creates a CompareViewerSwitchingPane as a child of the given parent and with the specified SWT style bits. | |
CompareViewerSwitchingPane(Composite parent,
int style,
boolean visibility)
Creates a CompareViewerSwitchingPane as a child of the given parent and with the specified SWT style bits. |
Method Summary | |
void | addDoubleClickListener(IDoubleClickListener l)
|
void | addOpenListener(IOpenListener l)
|
void | addSelectionChangedListener(ISelectionChangedListener l)
Adds a listener for selection changes in this selection provider. |
void | doubleClick(DoubleClickEvent event)
Notifies of a double click. |
Object | getInput()
Returns the current input of this pane or null if the pane has no input. |
ISelection | getSelection()
Returns the current selection for this provider. |
String | getTitleArgument()
Returns the optional title argument that has been set with setTitelArgument or null if no optional title argument has been set. |
Viewer | getViewer()
Returns the current viewer. |
protected abstract Viewer | getViewer(Viewer oldViewer,
Object input)
Returns a viewer which is able to display the given input. |
boolean | isEmpty()
Returns true if no viewer is installed or if the current viewer is a NullViewer. |
void | removeDoubleClickListener(IDoubleClickListener l)
|
void | removeOpenListener(IOpenListener l)
|
void | removeSelectionChangedListener(ISelectionChangedListener l)
Removes the given selection change listener from this selection provider. |
void | selectionChanged(SelectionChangedEvent ev)
Notifies that the selection has changed. |
void | setInput(Object input)
Sets the input object of this pane. |
void | setSelection(ISelection s)
Sets the current selection for this selection provider. |
void | setTitleArgument(String argument)
Sets an additional and optional argument for the pane's title. |
Methods inherited from class org.eclipse.compare.CompareViewerPane |
clearToolBar, getToolBarManager, setImage, setText |
Methods inherited from class org.eclipse.swt.custom.ViewForm |
computeSize, computeTrim, getClientArea, getContent, getTopCenter, getTopLeft, getTopRight, layout, setBorderVisible, setContent, setFont, setLayout, setTopCenter, setTopCenterSeparate, setTopLeft, setTopRight |
Methods inherited from class org.eclipse.swt.widgets.Composite |
checkSubclass, getChildren, getLayout, getTabList, layout, setFocus, setTabList |
Methods inherited from class org.eclipse.swt.widgets.Scrollable |
getHorizontalBar, getVerticalBar |
Methods inherited from class org.eclipse.swt.widgets.Widget |
addDisposeListener, addListener, checkWidget, dispose, getData, getData, getDisplay, getStyle, isDisposed, isListening, notifyListeners, removeDisposeListener, removeListener, removeListener, setData, setData, toString |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public CompareViewerSwitchingPane(Composite parent, int style)
public CompareViewerSwitchingPane(Composite parent, int style, boolean visibility)
Method Detail |
public Viewer getViewer()
public String getTitleArgument()
Note: this method is for internal use only. Clients should not call this method.
public boolean isEmpty()
public void addSelectionChangedListener(ISelectionChangedListener l)
public void removeSelectionChangedListener(ISelectionChangedListener l)
public void addDoubleClickListener(IDoubleClickListener l)
public void removeDoubleClickListener(IDoubleClickListener l)
public void addOpenListener(IOpenListener l)
public void removeOpenListener(IOpenListener l)
public void doubleClick(DoubleClickEvent event)
public ISelection getSelection()
public void setSelection(ISelection s)
public void selectionChanged(SelectionChangedEvent ev)
public void setInput(Object input)
public void setTitleArgument(String argument)
public Object getInput()
protected abstract Viewer getViewer(Viewer oldViewer, Object input)
|
Eclipse Platform Release 3.0 | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Guidelines for using Eclipse APIs.
Copyright (c) IBM Corp. and others 2000, 2004. All rights reserved.