Community
Participate
Working Groups
Setting org.eclipse.ui/PERSPECTIVE_BAR_EXTRAS=myPerspectiveId1,myPerspectiveId2 in plugin_customization.ini has no affect in Juno RC3.
Hi, We plan to migrate to eclipse 4.2 for our product. Does a workaround exist for this bug ? Any chance to see this bug fixed in a 4.2.1 version ? thx
I don't have anybody to look at this, but I'd consider a safe patch for 4.2.1. http://wiki.eclipse.org/Platform_UI/How_to_Contribute PW
Any ETA on a fix? The issue here is that the preferenceCustomization option is ignored, or at least the referenced file is not opened/used, since any option written in the file is ignored (whereas everything works fine on Juno). It's quite problematic for RCP application and plugin development. Thanks.
(In reply to comment #3) > Any ETA on a fix? No, as mentioned I don't have anybody to look at this but will accept a patch. PW
I think something is messed up in the IPageLayout, because even if try to read out the customization myself and process it in my PerspectiveFactory the shortcut is not added to the perspective-shortcut-bar, whereas the defaultPerspectiveId-option works as a charm. @Override public void createInitialLayout(final IPageLayout layout) { /* ... my other stuff ... */ String st = PlatformUI.getPreferenceStore().getDefaultString( IWorkbenchPreferenceConstants.PERSPECTIVE_BAR_EXTRAS); for (String s : st.split(",")) { layout.addPerspectiveShortcut(s); } } best regards Ben
At the moment I put the following code into the ApplicationWorkbenchWindowAdvisor:postWindowOpen method as the work around. And I'll try to find the time to create a patch it looks ok. EModelService modelService = (EMod:elService) PlatformUI.getWorkbench().getService(EModelService.class); MWindow model = ((WorkbenchWindow) window).getModel(); List<MPerspectiveStack> theStack = modelService.findElements(model, null, MPerspectiveStack.class, null); MPerspectiveStack _perspectiveStack=null; if (theStack.size() > 0) { _perspectiveStack = theStack.get(0); } IPerspectiveDescriptor perspect = PlatformUI.getWorkbench().getPerspectiveRegistry().findPerspectiveWithId(SimulationPerspective.ID); MPerspective pers = MAdvancedFactory.INSTANCE.createPerspective(); pers.setLabel(perspect.getLabel()); pers.setElementId(perspect.getId()); EPartService partService = (EPartService) window.getService(EPartService.class); IPerspectiveFactory factory = ((PerspectiveDescriptor) perspect).createFactory(); ModeledPageLayout modelLayout = new ModeledPageLayout(model, modelService, partService, pers, perspect, (WorkbenchPage) window.getActivePage(), true); factory.createInitialLayout(modelLayout); if(_perspectiveStack!=null) _perspectiveStack.getChildren().add(pers);
Submitted a patch for review: https://git.eclipse.org/r/#/c/34708/
Possibly a duplicate of the resolved Bug 479126 - PERSPECTIVE_BAR_EXTRAS setting not taken into account
(In reply to John Moule from comment #8) > Possibly a duplicate of the resolved Bug 479126 - PERSPECTIVE_BAR_EXTRAS > setting not taken into account Thanks. *** This bug has been marked as a duplicate of bug 479126 ***