[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Newsgroup Home]
[news.eclipse.platform.rcp] Re: Associate Editor with Perspective

Remy Suen wrote:

On Fri, 04 Sep 2009 14:22:34 +0000, Dave wrote:
Is there a way to do this?  Even if there is not a simple way to do it,
I am willing to consider more complicated ways.  Any suggestions?

We added new API in 3.5 which should help with this. Please see bug 11001.
https://bugs.eclipse.org/bugs/show_bug.cgi?id=11001

http://help.eclipse.org/stable/nftopic/org.eclipse.platform.doc.isv/
reference/api/org/eclipse/ui/IWorkbenchPage.html#showEditor%
28org.eclipse.ui.IEditorReference%29

http://help.eclipse.org/stable/nftopic/org.eclipse.platform.doc.isv/
reference/api/org/eclipse/ui/IWorkbenchPage.html#hideEditor%
28org.eclipse.ui.IEditorReference%29

As the API is new, there may be some problems with it. Please report bugs if you spot any problems. Thank you.

Regards,
Remy

Thanks for the information. The new API looks like the kind of thing I'm looking for. But I'm still a little confused as to how to use it to achieve what I want. Is there a recommendation as to where/when (i.e., class/method, listener event, etc.) to hide the editors, and where/when to re-show them? The API documentation says that getEditorReferences() does not return hidden editors. So how do I get the list of hidden editors that I want to re-show when a perspective is being re-shown? Note that I don't necessarily want to re-show all hidden editors, as there may be some hidden editors associated with perspectives that are not being re-shown. Any advice would be appreciated!