Package org.eclipse.ui
Class PerspectiveAdapter
java.lang.Object
org.eclipse.ui.PerspectiveAdapter
- All Implemented Interfaces:
IPerspectiveListener
,IPerspectiveListener2
,IPerspectiveListener3
,IPerspectiveListener4
- Direct Known Subclasses:
PerspectiveTracker
This adapter class provides default implementations for the methods described
by the
IPerspectiveListener
interface and its extension
interfaces.
Classes that wish to deal with events which occur as perspectives are added, removed, activated and changed, can extend this class and override only the methods which they are interested in.
- Since:
- 3.1
- See Also:
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
perspectiveActivated
(IWorkbenchPage page, IPerspectiveDescriptor perspective) Notifies this listener that a perspective in the given page has been activated.void
perspectiveChanged
(IWorkbenchPage page, IPerspectiveDescriptor perspective, String changeId) Notifies this listener that a perspective has changed in some way (for example, editor area hidden, perspective reset, view show/hide, editor open/close, etc).void
perspectiveChanged
(IWorkbenchPage page, IPerspectiveDescriptor perspective, IWorkbenchPartReference partRef, String changeId) Notifies this listener that a part in the given page's perspective has changed in some way (for example, view show/hide, editor open/close, etc).void
perspectiveClosed
(IWorkbenchPage page, IPerspectiveDescriptor perspective) Notifies this listener that a perspective in the given page has been closed.void
perspectiveDeactivated
(IWorkbenchPage page, IPerspectiveDescriptor perspective) Notifies this listener that a perspective in the given page has been deactivated.void
perspectiveOpened
(IWorkbenchPage page, IPerspectiveDescriptor perspective) Notifies this listener that a perspective in the given page has been opened.void
perspectivePreDeactivate
(IWorkbenchPage page, IPerspectiveDescriptor perspective) Notifies this listener that a perspective in the given page is about to be deactivated.void
perspectiveSavedAs
(IWorkbenchPage page, IPerspectiveDescriptor oldPerspective, IPerspectiveDescriptor newPerspective) Notifies this listener that a perspective in the given page has been saved as a new perspective with a different perspective descriptor.
-
Constructor Details
-
PerspectiveAdapter
public PerspectiveAdapter()
-
-
Method Details
-
perspectiveOpened
Description copied from interface:IPerspectiveListener3
Notifies this listener that a perspective in the given page has been opened.- Specified by:
perspectiveOpened
in interfaceIPerspectiveListener3
- Parameters:
page
- the page containing the opened perspectiveperspective
- the perspective descriptor that was opened- See Also:
-
perspectiveClosed
Description copied from interface:IPerspectiveListener3
Notifies this listener that a perspective in the given page has been closed.- Specified by:
perspectiveClosed
in interfaceIPerspectiveListener3
- Parameters:
page
- the page containing the closed perspectiveperspective
- the perspective descriptor that was closed- See Also:
-
perspectiveChanged
public void perspectiveChanged(IWorkbenchPage page, IPerspectiveDescriptor perspective, IWorkbenchPartReference partRef, String changeId) Description copied from interface:IPerspectiveListener2
Notifies this listener that a part in the given page's perspective has changed in some way (for example, view show/hide, editor open/close, etc).- Specified by:
perspectiveChanged
in interfaceIPerspectiveListener2
- Parameters:
page
- the workbench page containing the perspectiveperspective
- the descriptor for the changed perspectivepartRef
- the reference to the affected partchangeId
- one of theCHANGE_*
constants on IWorkbenchPage
-
perspectiveActivated
Description copied from interface:IPerspectiveListener
Notifies this listener that a perspective in the given page has been activated.- Specified by:
perspectiveActivated
in interfaceIPerspectiveListener
- Parameters:
page
- the page containing the activated perspectiveperspective
- the perspective descriptor that was activated- See Also:
-
perspectiveChanged
public void perspectiveChanged(IWorkbenchPage page, IPerspectiveDescriptor perspective, String changeId) Description copied from interface:IPerspectiveListener
Notifies this listener that a perspective has changed in some way (for example, editor area hidden, perspective reset, view show/hide, editor open/close, etc).- Specified by:
perspectiveChanged
in interfaceIPerspectiveListener
- Parameters:
page
- the page containing the affected perspectiveperspective
- the perspective descriptorchangeId
- one of theCHANGE_*
constants on IWorkbenchPage
-
perspectiveDeactivated
Description copied from interface:IPerspectiveListener3
Notifies this listener that a perspective in the given page has been deactivated.- Specified by:
perspectiveDeactivated
in interfaceIPerspectiveListener3
- Parameters:
page
- the page containing the deactivated perspectiveperspective
- the perspective descriptor that was deactivated- See Also:
-
perspectiveSavedAs
public void perspectiveSavedAs(IWorkbenchPage page, IPerspectiveDescriptor oldPerspective, IPerspectiveDescriptor newPerspective) Description copied from interface:IPerspectiveListener3
Notifies this listener that a perspective in the given page has been saved as a new perspective with a different perspective descriptor.- Specified by:
perspectiveSavedAs
in interfaceIPerspectiveListener3
- Parameters:
page
- the page containing the saved perspectiveoldPerspective
- the old perspective descriptornewPerspective
- the new perspective descriptor- See Also:
-
perspectivePreDeactivate
Notifies this listener that a perspective in the given page is about to be deactivated.
Note: This does not have the ability to veto a perspective deactivation.
- Specified by:
perspectivePreDeactivate
in interfaceIPerspectiveListener4
- Parameters:
page
- the page containing the deactivated perspectiveperspective
- the perspective descriptor that was deactivated- Since:
- 3.2
- See Also:
-