Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Rich Client Platform (RCP) » Couple editor to perspective?
Couple editor to perspective? [message #523939] Mon, 29 March 2010 22:33 Go to next message
Eric Jain is currently offline Eric JainFriend
Messages: 266
Registered: July 2009
Senior Member
I'd like to switch (or at least prompt the user about switching) to a certain perspective when a custom editor is opened.

When the editor is closed (or another editor is in focus), I'd like to switch back to the previous perspective.

Is there a simple way to accomplish this?
Re: Couple editor to perspective? [message #523995 is a reply to message #523939] Tue, 30 March 2010 08:42 Go to previous messageGo to next message
Devi Vara Prasad Bandaru is currently offline Devi Vara Prasad BandaruFriend
Messages: 100
Registered: March 2010
Location: Hyderabad
Senior Member

Hi,
You can try using org.eclipse.ui.IPartListener and handle the perpspective switch in the editor activate/deactivate events.


Re: Couple editor to perspective? [message #524121 is a reply to message #523995] Tue, 30 March 2010 20:16 Go to previous messageGo to next message
Eric Jain is currently offline Eric JainFriend
Messages: 266
Registered: July 2009
Senior Member
Thanks! I'm now associating every editor in the application with a specific perspective, which is opened on activation (through an IPartListener).
Re: Couple editor to perspective? [message #524273 is a reply to message #524121] Wed, 31 March 2010 11:34 Go to previous message
Ralf Ebert is currently offline Ralf EbertFriend
Messages: 168
Registered: July 2009
Senior Member
Am 30.03.10 22:16, schrieb Eric Jain:
> Thanks! I'm now associating every editor in the application with a
> specific perspective, which is opened on activation (through an
> IPartListener).

This recipe also helpful to you:
http://www.ralfebert.de/blog/eclipsercp/auto_perspective_swi tch/

Greetings,

Ralf

--
http://www.ralfebert.de/blog/
http://twitter.com/ralfebert/
Previous Topic:How to get menumanager of Main menu in a treeviewer
Next Topic:Refresh CommenNavigator
Goto Forum:
  


Current Time: Fri Apr 19 15:37:07 GMT 2024

Powered by FUDForum. Page generated in 0.02356 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top