contribution to Papyrus perspective [message #705054] |
Fri, 29 July 2011 07:25  |
Eclipse User |
|
|
|
Hi,
I created my own menu and toolbar, and I can see them unless the papyrus perspective is active. A solution was submitted in a previous post, i.e. using org.eclipse.papyrus.ui.perspectiveconfiguration to configure papyrus perspective in order to add menus and toolbar IDs to it. But I can't make it work. Both menu and toolbar don't show up.
Below a part of my plugin.xml :
<extension
point="org.eclipse.ui.menus">
<menuContribution
locationURI="menu:org.eclipse.ui.main.menu">
<menu
id="my.own.menu"
label="My Own Menu">
<command
commandID="my.own.command.first"
label="First Item"
style="push">
</command>
<command
commandID="my.own.command.second"
label="Second Item"
style="push">
</command>
</menu>
</menuContribution>
<menuContribution
locationURI="toolbar:org.eclipse.ui.main.toolbar">
<toolbar
id="my.own.toolbar">
<command
commandId="my.own.command.first"
icon="icons/td_check.png"
label="First Item"
style="push">
</command>
<command
commandId="my.own.command.second"
icon="icons/td_logo.png"
label="Second Item"
style="push">
</command>
</toolbar>
</menuContribution>
</extension>
<extension
point="org.eclipse.ui.commands">
<command
categoryId="my.own.category"
defaultHandler="my.own.command.FirstHandler"
id=""my.own.command.first"
name="First Item">
</command>
<command
categoryId="my.own.category"
defaultHandler="my.own.command.SecondHandler"
id="my.own.command.second"
name="Second Item">
</command>
<category
id="my.own.category"
name="MyOwnCategory">
</category>
</extension>
I tried several technics, here they are :
First, with keeping the example from the previous post
<extension
point="org.eclipse.papyrus.ui.perspectiveconfiguration">
<configuration
perspectiveID="org.eclipse.papyrus.core.perspective">
<menu
menuID="file">
</menu>
<menu
menuID="edit">
</menu>
<menu
menuID="org.eclipse.papyrus.ui.menu">
</menu>
<menu
menuID="my.own.menu">
</menu>
<menu
menuID="window">
</menu>
<menu
menuID="help">
</menu>
<toolbar
toolbarID="my.own.toolbar">
</toolbar>
<toolbar
toolbarID="org.eclipse.papyrus.diagram.ui.toolbar">
</toolbar>
<preferencePage
preferencepageID="org.eclipse.papyrus.preferences.generalcategory">
</preferencePage>
<category
categoryID="org.eclipse.ui.category.file">
</category>
<category
categoryID="org.eclipse.ui.category.edit">
</category>
<category
categoryID="org.eclipse.ui.category.help">
</category>
<category
categoryID="org.eclipse.papyrus.editor.category">
</category>
<category
categoryID="my.own.category">
</category>
</configuration>
</extension>
Second, with starting from scratch
<extension
point="org.eclipse.papyrus.ui.perspectiveconfiguration">
<configuration
perspectiveID="org.eclipse.papyrus.core.perspective">
<menu
menuID="my.own.menu">
</menu>
<toolbar
toolbarID="my.own.toolbar">
<category
categoryID="my.own.category">
</category>
</configuration>
</extension>
Also I tried without declaring "my.own.category", didn't change a thing.
Any Idea why this is not working ? Thank you.
|
|
|
|
Powered by
FUDForum. Page generated in 0.03400 seconds