is it possible to extend an existing extenstion point (org.eclipse.ui.perspectives)? Of course I could write a new one but how gonna tell I my RCP application to handle it as perspective extension point?
On 26.10.2010 09:27, jasda@web.de wrote:
> is it possible to extend an existing extenstion point
> (org.eclipse.ui.perspectives)? Of course I could write a new one but
> how gonna tell I my RCP application to handle it as perspective
> extension point?
I'm not sure what you mean with this: There is no portable way to
replace the way an existing extension point will be evaluated unless
it is your own code.
It is perfectly possible to re-parse any existing extension point when
you know the ID and do something with the outcome of this processing,
but I would not consider this as an "extension" of an existing extension
point, though.
What do you want to realize? Why do you not provide your own extension
point?
Unfortunately in Eclipse the editor area is not bound to perspectives, but in our application it is still necessary. When the perspective is changed a new or existing editor should be shown.
So far I've implements a perspective change listener:
@Override
public void perspectiveActivated(IWorkbenchPage page, IPerspectiveDescriptor perspective)
{
IEditorReference[] editors = page.getEditorReferences();
if (editors != null)
{
for (int i=0; i<editors.length; i++)
{
if (!editors[i].getId().equals(perspective.getAttributes().get("editorId"))
page.hideEditor(editors[i]);
}
}
});
At this point it would be nice to be able to get the editor id that is was bound to the perspective in its extension point.