[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[news.eclipse.platform] Re: Help with adding wizard shortcut

Andrei Serea wrote:

I want to add my wizard directly to the "new" submenu of the File menu but I can't quite succeed.
I have created my own category where i've put the wizard and registered an extension to the org.eclipse.ui.perspectiveExtensions extension point to add my wizard shortcut as an extension to the Java Perspective.
Here is the part of the plugin.xml file that does that:
<extension

point="org.eclipse.ui.perspectiveExtensions">

<perspectiveExtension targetID="org.eclipse.jdt.ui.JavaPerspective">

<newWizardShortcut id="org.ama.ide.newWizards.newClass"/>

</perspectiveExtension>

<perspectiveExtension targetID="org.eclipse.jdt.ui.JavaBrowsingPerspective">

<newWizardShortcut id="org.ama.ide.newWizards.newClass"/>

</perspectiveExtension>

</extension>

Now, what am I doing wrong? Please help asap!

10x

To add a shortcut to your wizard in on toolbar you must implements the org.eclipse.ui.actionSets Extension Point.


To add the access to your wizard in the new menu I suggest to implement the IPerspectiveFactory interface, and in its createInitialLayout(IPageLayout layout) method add something like this :

layout.addNewWizardShortcut(yourWizardID);

Hope it will help

Dimitri.