|
Eclipse Platform Release 3.6 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.eclipse.core.commands.common.EventManager
org.eclipse.ui.part.WorkbenchPart
org.eclipse.ui.part.ViewPart
org.eclipse.ui.part.PageBookView
org.eclipse.ui.views.properties.PropertySheet
public class PropertySheet
Main class for the Property Sheet View.
This standard view has id "org.eclipse.ui.views.PropertySheet".
Note that property IPropertySheetPages.
Property sheet pages are discovered by the property sheet view automatically
when a part is first activated. The property sheet view asks the active part
for its property sheet page; this is done by invoking
getAdapter(IPropertySheetPage.class) on the part. If the part
returns a page, the property sheet view then creates the controls for that
property sheet page (using createControl), and adds the page to
the property sheet view. Whenever this part becomes active, its corresponding
property sheet page is shown in the property sheet view (which may or may not
be visible at the time). A part's property sheet page is discarded when the
part closes. The property sheet view has a default page (an instance of
PropertySheetPage) which services all parts without a property
sheet page of their own.
The workbench will automatically instantiates this class when a Property Sheet view is needed for a workbench window. This class is not intended to be instantiated or subclassed by clients.
IPropertySheetPage,
PropertySheetPage| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class org.eclipse.ui.part.PageBookView |
|---|
PageBookView.PageRec, PageBookView.SelectionProvider |
| Field Summary | |
|---|---|
static java.lang.String |
HELP_CONTEXT_PROPERTY_SHEET_VIEW
No longer used but preserved to avoid api change |
| Fields inherited from interface org.eclipse.ui.IWorkbenchPart |
|---|
PROP_TITLE |
| Constructor Summary | |
|---|---|
PropertySheet()
Creates a property sheet view. |
|
| Method Summary | |
|---|---|
void |
added(IExtension[] extensions)
Notifies this listener that extensions were added to the registry. |
void |
added(IExtensionPoint[] extensionPoints)
Notifies this listener that extension points were added to the registry. |
protected IPage |
createDefaultPage(PageBook book)
Creates and returns the default page for this view. |
void |
createPartControl(Composite parent)
The PropertySheet implementation of this IWorkbenchPart
method creates a PageBook control with its default page showing. |
void |
dispose()
The PageBookView implementation of this
IWorkbenchPart method cleans up all the pages. |
protected PageBookView.PageRec |
doCreatePage(IWorkbenchPart part)
Creates a new page in the pagebook for a particular part. |
protected void |
doDestroyPage(IWorkbenchPart part,
PageBookView.PageRec rec)
Destroys a page in the pagebook for a particular part. |
protected IWorkbenchPart |
getBootstrapPart()
Returns the active, important workbench part for this view. |
protected ISaveablePart |
getSaveablePart()
Returns an ISaveablePart that delegates to the source part
for the current page if it implements ISaveablePart, or
null otherwise. |
ShowInContext |
getShowInContext()
Returns the context to show, or null if there is
currently no valid context to show. |
protected java.lang.Object |
getViewAdapter(java.lang.Class key)
The PropertySheet implementation of this
PageBookView method handles the ISaveablePart
adapter case by calling getSaveablePart(). |
void |
init(IViewSite site)
Initializes this view with the given view site. |
protected boolean |
isImportant(IWorkbenchPart part)
Returns whether the given part should be added to this view. |
boolean |
isPinned()
|
void |
partActivated(IWorkbenchPart part)
The PropertySheet implementation of this IPartListener
method first sees if the active part is an IContributedContentsView
adapter and if so, asks it for its contributing part. |
void |
partClosed(IWorkbenchPart part)
The PageBookView implementation of this
IPartListener method deal with the closing of the active
part. |
protected void |
partHidden(IWorkbenchPart part)
Make sure that the part is not considered if it is hidden. |
protected void |
partVisible(IWorkbenchPart part)
Make sure that the part is not considered if it is hidden. |
void |
removed(IExtension[] extensions)
Notifies this listener that extensions were removed from the registry. |
void |
removed(IExtensionPoint[] extensionPoints)
Notifies this listener that extension points were removed from the registry. |
void |
saveState(IMemento memento)
Saves the state of the object in the given memento. |
void |
selectionChanged(IWorkbenchPart part,
ISelection sel)
Notifies this listener that the selection has changed. |
void |
setPinned(boolean pinned)
|
boolean |
show(ShowInContext aContext)
Shows the given context in this target. |
| Methods inherited from class org.eclipse.ui.part.PageBookView |
|---|
doesPageExist, getAdapter, getCurrentContributingPart, getCurrentPage, getDefaultPage, getPageBook, getPageRec, getPageRec, getPageSite, getSelectionProvider, initPage, partBroughtToTop, partDeactivated, partOpened, setFocus, showPageRec |
| Methods inherited from class org.eclipse.ui.part.ViewPart |
|---|
checkSite, getViewSite, init, setContentDescription, setInitializationData, setPartName |
| Methods inherited from class org.eclipse.ui.part.WorkbenchPart |
|---|
addPartPropertyListener, addPropertyListener, firePartPropertyChanged, firePropertyChange, getConfigurationElement, getContentDescription, getDefaultImage, getOrientation, getPartName, getPartProperties, getPartProperty, getSite, getTitle, getTitleImage, getTitleToolTip, removePartPropertyListener, removePropertyListener, setPartProperty, setSite, setTitle, setTitleImage, setTitleToolTip, showBusy |
| Methods inherited from class org.eclipse.core.commands.common.EventManager |
|---|
addListenerObject, clearListeners, getListeners, isListenerAttached, removeListenerObject |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.eclipse.ui.IWorkbenchPart |
|---|
addPropertyListener, getSite, getTitle, getTitleImage, getTitleToolTip, removePropertyListener |
| Field Detail |
|---|
public static final java.lang.String HELP_CONTEXT_PROPERTY_SHEET_VIEW
| Constructor Detail |
|---|
public PropertySheet()
| Method Detail |
|---|
protected IPage createDefaultPage(PageBook book)
PageBookViewSubclasses must implement this method.
Subclasses must call initPage with the new page (if it is an
IPageBookViewPage) before calling createControl on the
page.
createDefaultPage in class PageBookViewbook - the pagebook control
public void createPartControl(Composite parent)
PropertySheet implementation of this IWorkbenchPart
method creates a PageBook control with its default page showing.
createPartControl in interface IWorkbenchPartcreatePartControl in class PageBookViewparent - the parent controlpublic void dispose()
PageBookViewPageBookView implementation of this
IWorkbenchPart method cleans up all the pages. Subclasses
may extend.
dispose in interface IWorkbenchPartdispose in class PageBookViewprotected PageBookView.PageRec doCreatePage(IWorkbenchPart part)
PageBookViewdoDestroyPage.
Subclasses must implement this method.
Subclasses must call initPage with the new page (if it is an
IPageBookViewPage) before calling createControl on the
page.
doCreatePage in class PageBookViewpart - the input part
PageBookView.doDestroyPage(org.eclipse.ui.IWorkbenchPart, org.eclipse.ui.part.PageBookView.PageRec)
protected void doDestroyPage(IWorkbenchPart part,
PageBookView.PageRec rec)
PageBookViewdoCreatePage.
Subclasses must implement this method.
doDestroyPage in class PageBookViewpart - the input partrec - a page record for the partPageBookView.doCreatePage(org.eclipse.ui.IWorkbenchPart)protected IWorkbenchPart getBootstrapPart()
PageBookView
When the page book view is created it has no idea which part within the
workbook should be used to generate the first page. Therefore, it
delegates the choice to subclasses of PageBookView.
Implementors of this method should return an active, important part in
the workbench or null if none found.
Subclasses must implement this method.
getBootstrapPart in class PageBookViewnull if none
public void init(IViewSite site)
throws PartInitException
IViewPartThis method is automatically called by the workbench shortly after the part is instantiated. It marks the start of the views's lifecycle. Clients must not call this method.
init in interface IViewPartinit in class PageBookViewsite - the view site
PartInitException - if this view was not initialized successfullypublic void saveState(IMemento memento)
IPersistable
saveState in interface IPersistablesaveState in interface IViewPartsaveState in class ViewPartmemento - the storage area for object's stateprotected boolean isImportant(IWorkbenchPart part)
PageBookViewSubclasses must implement this method.
isImportant in class PageBookViewpart - the input part
true if the part is relevant, and
false otherwisepublic void partClosed(IWorkbenchPart part)
PageBookViewPageBookView implementation of this
IPartListener method deal with the closing of the active
part. Subclasses may extend.
partClosed in interface IPartListenerpartClosed in class PageBookViewpart - the part that was closedIWorkbenchPage.hideView(IViewPart)protected void partVisible(IWorkbenchPart part)
PageBookView
partVisible in class PageBookViewprotected void partHidden(IWorkbenchPart part)
PageBookView
partHidden in class PageBookViewpublic void partActivated(IWorkbenchPart part)
PropertySheet implementation of this IPartListener
method first sees if the active part is an IContributedContentsView
adapter and if so, asks it for its contributing part.
partActivated in interface IPartListenerpartActivated in class PageBookViewpart - the part that was activatedIWorkbenchPage.activate(org.eclipse.ui.IWorkbenchPart)
public void selectionChanged(IWorkbenchPart part,
ISelection sel)
ISelectionListener
This method is called when the selection changes from one to a
non-null value, but not when the selection changes to
null. If there is a requirement to be notified in the latter
scenario, implement INullSelectionListener. The event will
be posted through this method.
selectionChanged in interface ISelectionListenerpart - the workbench part containing the selectionsel - the current selection. This may be null
if INullSelectionListener is implemented.protected java.lang.Object getViewAdapter(java.lang.Class key)
PropertySheet implementation of this
PageBookView method handles the ISaveablePart
adapter case by calling getSaveablePart().
getViewAdapter in class PageBookViewkey - the adapter class to look up
null if
this object does not have an adapter for the given classprotected ISaveablePart getSaveablePart()
ISaveablePart that delegates to the source part
for the current page if it implements ISaveablePart, or
null otherwise.
ISaveablePart or nullpublic boolean isPinned()
public ShowInContext getShowInContext()
null if there is
currently no valid context to show.
getShowInContext in interface IShowInSourcenullpublic boolean show(ShowInContext aContext)
show in interface IShowInTargetaContext - the context to show
true if the context could be shown,
false otherwisepublic void setPinned(boolean pinned)
pinned - Whether this sheet should be pinnedpublic void added(IExtension[] extensions)
IRegistryEventListenerThe extensions supplied as the argument are valid only for the duration of the invocation of this method.
added in interface IRegistryEventListenerextensions - extensions added to the registryIRegistryEventListener.added(org.eclipse.core.runtime.IExtension[])public void added(IExtensionPoint[] extensionPoints)
IRegistryEventListenerThe extension points supplied as the argument are valid only for the duration of the invocation of this method.
added in interface IRegistryEventListenerextensionPoints - extension points added to the registryIRegistryEventListener.added(org.eclipse.core.runtime.IExtensionPoint[])public void removed(IExtension[] extensions)
IRegistryEventListenerThe extensions supplied as the argument are valid only for the duration of the invocation of this method.
removed in interface IRegistryEventListenerextensions - extensions removed from the registryIRegistryEventListener.removed(org.eclipse.core.runtime.IExtension[])public void removed(IExtensionPoint[] extensionPoints)
IRegistryEventListenerThe extension points supplied as the argument are valid only for the duration of the invocation of this method.
removed in interface IRegistryEventListenerextensionPoints - extension points removed from the registryIRegistryEventListener.removed(org.eclipse.core.runtime.IExtensionPoint[])
|
Eclipse Platform Release 3.6 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
Guidelines for using Eclipse APIs.
Copyright (c) Eclipse contributors and others 2000, 2010. All rights reserved.