createInitialLayout method not called when initializing a new perspective [message #326482] |
Thu, 20 March 2008 16:29 |
Eclipse User |
|
|
|
Originally posted by: massimiliano.fanciulli.intecs.it
Hi all,
i have added a new perspective to my plugin, following those steps
described into the documentation. i have added the following to the
plugin.xml file:
<extension
point="org.eclipse.ui.perspectives">
<perspective
class="it.intecs.pisa.develenv.ui.perspectives.developPerspective "
fixed="false"
icon="icons/Toolbox_gear_blue.jpg"
id="com.intecs.ToolboxScript.ui.developPerspective"
name="TOOLBOX_develop">
<description/>
</perspective>
</extension>
Then i have created the class
it.intecs.pisa.develenv.ui.perspectives.developPerspective and populated
the method createInitialLayout as follows:
public void createInitialLayout(IPageLayout layout) {
String editorArea = layout.getEditorArea();
// Top left: Resource Navigator view and Bookmarks view placeholder
IFolderLayout topLeft = layout.createFolder("topLeft",
IPageLayout.LEFT, 0.25f,editorArea);
topLeft.addView(IPageLayout.ID_RES_NAV);
topLeft.addPlaceholder(IPageLayout.ID_BOOKMARKS);
// Bottom left: Outline view and Property Sheet view
IFolderLayout bottomLeft = layout.createFolder("bottomLeft",
IPageLayout.BOTTOM, 0.50f,"topLeft");
bottomLeft.addView(IPageLayout.ID_OUTLINE);
bottomLeft.addView(IPageLayout.ID_PROP_SHEET);
// Bottom right: Task List view
layout.addView(IPageLayout.ID_OUTLINE,
IPageLayout.TOP|IPageLayout.LEFT, 0.33f, editorArea);
}
When running the plugin, the perspective is listed but, when selected,
it doesn't show any view. Do you know why? Do you have any tutorial that
i can read? Unfortunately i haven't found good documentation about it yet.
Thank you in advance.
Regards,
Massimiliano Fanciulli
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.03323 seconds