Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse 4 » perspective bar
perspective bar [message #1080852] Tue, 06 August 2013 13:00 Go to next message
Patrick Sowada is currently offline Patrick SowadaFriend
Messages: 6
Registered: July 2009
Junior Member
Hi,

does anybody here know who can i active/display the perspective bar?

My RCP application has two perspectives and i want active the icons in the right top corner like in ecplise 3.x.

I use eclipse 4.2.2. My implemented perspective switcher action works fine but normally i want to switch the perspective like in eclipse 3.x.

[Updated on: Wed, 07 August 2013 05:22]

Report message to a moderator

Re: perspective bar [message #1081066 is a reply to message #1080852] Tue, 06 August 2013 19:14 Go to previous messageGo to next message
Jason Lee is currently offline Jason LeeFriend
Messages: 3
Registered: March 2012
Junior Member
I have the same question actually.
Re: perspective bar [message #1082435 is a reply to message #1081066] Thu, 08 August 2013 15:05 Go to previous messageGo to next message
Eric Moffatt is currently offline Eric MoffattFriend
Messages: 118
Registered: July 2009
Senior Member
The current implementation of the Perspective Switcher is, unfortunately, tied to the Eclipse IDE and isn't available in pure e4 apps. We do intend to address this as part of an overall move to make the IDE code more self-contained so that our current need to access the WorkbenchPage can be removed.
Re: perspective bar [message #1172516 is a reply to message #1082435] Wed, 06 November 2013 00:23 Go to previous messageGo to next message
Ozgur Cagdas is currently offline Ozgur CagdasFriend
Messages: 29
Registered: May 2013
Junior Member
Hi Eric,

Is there an estimated date for this to be implemented by any chance? I'm just about to add multiple perspectives and wanted to check before doing anything custom.

Regards,

Ozgur.
Re: perspective bar [message #1173792 is a reply to message #1172516] Wed, 06 November 2013 19:13 Go to previous messageGo to next message
Eric Moffatt is currently offline Eric MoffattFriend
Messages: 118
Registered: July 2009
Senior Member

This is (unfortunately) not even on our radar right now, note that you can likely get away with cloning the compatibility implementation and just cut out the 3.x specific code to get what you need. This would mean for example not calling the workbenchpage's 'setPerspective' method but just setting the MPerspectiveStack's selectedElement...
Re: perspective bar [message #1184243 is a reply to message #1173792] Wed, 13 November 2013 10:15 Go to previous message
Ozgur Cagdas is currently offline Ozgur CagdasFriend
Messages: 29
Registered: May 2013
Junior Member
Thanks Eric, that does work. It might already be obvious how to achieve this for many but I've also pasted the below snippet to show how to get hold of the perspective stack and its perspectives.

@Inject
MApplication application;

void dummyForce1stPerspectiveActivation() {
	MWindow l = application.getChildren().get(0);
	MPerspectiveStack stack = (MPerspectiveStack)l.getChildren().get(0);
        MPerspective perspective = stack.getChildren().get(0);
        stack.setSelectedElement(perspective);
}
Previous Topic:Part on top of a PartSashContainer
Next Topic:Eclipse 4 on Red Hat Linux
Goto Forum:
  


Current Time: Fri Nov 28 17:12:05 GMT 2014

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

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