2 package net.sourceforge.phpeclipse;
4 import org.eclipse.debug.ui.IDebugUIConstants;
5 import org.eclipse.ui.IFolderLayout;
6 import org.eclipse.ui.IPageLayout;
7 import org.eclipse.ui.IPerspectiveFactory;
9 public class PHPPerspectiveFactory implements IPerspectiveFactory {
11 public PHPPerspectiveFactory() {
15 public void createInitialLayout(IPageLayout layout) {
16 String editorArea = layout.getEditorArea();
18 // IFolderLayout phpResourcesArea = layout.createFolder("phpresourcesarea", IPageLayout.LEFT, (float)0.25, editorArea);
19 // phpResourcesArea.addView(PHPeclipsePlugin.PHP_RESOURCES_VIEW_ID);
20 IFolderLayout folder= layout.createFolder("left", IPageLayout.LEFT, (float)0.25, editorArea); //$NON-NLS-1$
21 folder.addView(IPageLayout.ID_RES_NAV);
22 folder.addPlaceholder(IPageLayout.ID_RES_NAV);
24 IFolderLayout consoleArea = layout.createFolder("consoleArea", IPageLayout.BOTTOM, (float)0.75, editorArea);
26 consoleArea.addView(IPageLayout.ID_TASK_LIST);
27 consoleArea.addView(IDebugUIConstants.ID_CONSOLE_VIEW);
28 consoleArea.addPlaceholder(IPageLayout.ID_BOOKMARKS);
30 layout.addView(IPageLayout.ID_OUTLINE, IPageLayout.RIGHT, (float)0.75, editorArea);
32 layout.addActionSet(IDebugUIConstants.LAUNCH_ACTION_SET);
34 layout.addShowViewShortcut(IDebugUIConstants.ID_CONSOLE_VIEW);
36 layout.addShowViewShortcut(PHPeclipsePlugin.PHP_RESOURCES_VIEW_ID);
38 // views - standard workbench
39 layout.addShowViewShortcut(IPageLayout.ID_OUTLINE);
40 layout.addShowViewShortcut(IPageLayout.ID_TASK_LIST);
42 // new actions - PHP project creation wizards
43 layout.addNewWizardShortcut("org.eclipse.ui.wizards.new.folder");//$NON-NLS-1$
44 layout.addNewWizardShortcut("org.eclipse.ui.wizards.new.file");//$NON-NLS-1$