Skip to main content



      Home
Home » Eclipse Projects » Rich Client Platform (RCP) » My new wizard disappeared switching from 3.11 to 3.2RC2
My new wizard disappeared switching from 3.11 to 3.2RC2 [message #449062] Tue, 09 May 2006 19:51 Go to next message
Eclipse UserFriend
My new wizard - that was working OK before the switch stopped once I build
with 3.2RC2 against a 3.2RC2 target.

The original extension looked like this:
---8<---
<extension
point="org.eclipse.ui.newWizards">
<wizard

category="com.lesliesoftware.wizardsfamiliar.deck.editor.category "

class=" com.lesliesoftware.wizardsfamiliar.deck.editor.wizards.DeckC reationWizard "

finalPerspective="com.lesliesoftware.wizardsfamiliar.perspective.design "
icon="icons/sample.gif"

id=" com.lesliesoftware.wizardsfamiliar.deck.editor.wizards.DeckC reationWizard "
name="Deck">
<selection class="org.eclipse.core.resources.IResource"/>
</wizard>
</extension>
--->8---

The selection class always bothered me (since that class is not available
in my RCP target and I do not make use of IResource). When I switched to
3.2RC2 I received a warning about that line and my new wizard did not show
up any more. I have tried various things to fix it to no avail. I tried
removing the selection element. I tried choosing some other class that
does exist in my RCP app. What should that entry be? Is there a document
that describes changes between 3.1 and 3.2?

Any advice would be appreciated.

Thanks,

Ian
Re: My new wizard disappeared switching from 3.11 to 3.2RC2 [message #449063 is a reply to message #449062] Tue, 09 May 2006 21:05 Go to previous messageGo to next message
Eclipse UserFriend
If you are not shipping the resources plug-in then you can safely remove
the selection entry. Still such a change in the behavior is weird and
you might want to open a bug report with an example explaining the
change of behavior.

PaScaL

Ian Leslie wrote:
> My new wizard - that was working OK before the switch stopped once I
> build with 3.2RC2 against a 3.2RC2 target.
>
> The original extension looked like this:
> ---8<---
> <extension
> point="org.eclipse.ui.newWizards">
> <wizard
>
> category="com.lesliesoftware.wizardsfamiliar.deck.editor.category "
>
> class=" com.lesliesoftware.wizardsfamiliar.deck.editor.wizards.DeckC reationWizard "
>
>
> finalPerspective="com.lesliesoftware.wizardsfamiliar.perspective.design "
> icon="icons/sample.gif"
>
> id=" com.lesliesoftware.wizardsfamiliar.deck.editor.wizards.DeckC reationWizard "
>
> name="Deck">
> <selection class="org.eclipse.core.resources.IResource"/>
> </wizard>
> </extension>
> --->8---
>
> The selection class always bothered me (since that class is not
> available in my RCP target and I do not make use of IResource). When I
> switched to 3.2RC2 I received a warning about that line and my new
> wizard did not show up any more. I have tried various things to fix it
> to no avail. I tried removing the selection element. I tried choosing
> some other class that does exist in my RCP app. What should that entry
> be? Is there a document that describes changes between 3.1 and 3.2?
>
> Any advice would be appreciated.
>
> Thanks,
>
> Ian
>
Re: My new wizard disappeared switching from 3.11 to 3.2RC2 [message #449089 is a reply to message #449063] Wed, 10 May 2006 07:37 Go to previous messageGo to next message
Eclipse UserFriend
Pascal Rapicault wrote:

> If you are not shipping the resources plug-in then you can safely remove
> the selection entry. Still such a change in the behavior is weird and
> you might want to open a bug report with an example explaining the
> change of behavior.

> PaScaL

I created a simple RCP application with a new wizard using Eclipse 3.11
and then switched it to Eclipse 3.2RC2 in order to reproduce my problem
but it worked just fine. Then I tried to solve my other new wizard
problem using my newly working test - get my wizard to appear as a primary
wizard. So I added the primaryWizard element:
<extension
point="org.eclipse.ui.newWizards">
<category
id="NewWizardTest"
name="Test Wizards"/>
<wizard
category="NewWizardTest"
class="newWizardTest.wizards.TestNewWizard"
icon="icons/sample.gif"
id="newWizardTest.wizards.TestNewWizard"
name="Multi-page Editor file"/>
<primaryWizard id="newWizardTest.wizards.TestNewWizard"/>
</extension>

and it failed. Now when I press Ctrl-N I get an empty wizard dialog box.
With out the primaryWizard element things are fine:
<extension
point="org.eclipse.ui.newWizards">
<category
id="NewWizardTest"
name="Test Wizards"/>
<wizard
category="NewWizardTest"
class="newWizardTest.wizards.TestNewWizard"
icon="icons/sample.gif"
id="newWizardTest.wizards.TestNewWizard"
name="Multi-page Editor file"/>
</extension>

Yes, that worked in my main application too. When I removed the
primaryWizard element things worked again. Previously that element had no
effect (positive or negative).

Thanks,

Ian
How do I get my new wizard to show up as special (was Re: My new wizard...) [message #449091 is a reply to message #449089] Wed, 10 May 2006 07:48 Go to previous messageGo to next message
Eclipse UserFriend
By special I mean in the drop down above the "Other..." item or in the
"New>" flyout menu before the "Other..." menu item.

For example in the SDK (mine at least) both places have a list of new
wizards such as "Prject", "Package", "Class" etc. before the "Other..."
item in both places. How do I get that for my RCP application.

I tried specifying my wizard as a primary wizards but (see my previous
post) that meant my wizard did not appear at all.

In my ActionBarAdvisor class I have the following in my makeActions method:
---8<---
myNewDropDownAction =
ActionFactory.NEW_WIZARD_DROP_DOWN.create(window);
register (myNewDropDownAction);

// This is only used to register the action key (see the file
menu creation method for
// how the new menu command is created)
myNewWizardAction = ActionFactory.NEW.create(window);
register (myNewWizardAction);
--->8---

In my createFileMenu method I have:
---8<---
private MenuManager createFileMenu () {
// Create the file menu
MenuManager fileMenu = new MenuManager (
Messages.getString
("ApplicationActionBarAdvisor.Menu.File"), //$NON-NLS-1$
IWorkbenchActionConstants.M_FILE);

// Populate the file menu
fileMenu.add (new GroupMarker
(IWorkbenchActionConstants.FILE_START));
fileMenu.add (createNewSubMenu ());
fileMenu.add(new GroupMarker(IWorkbenchActionConstants.NEW_EXT));
fileMenu.add(new Separator());
--->8---

and createNewSubMenu looks like:
---8<---
private MenuManager createNewSubMenu () {
// create the New submenu, using the same id for it as the New
action
String newText =
Messages.getString("ApplicationActionBarAdvisor.Menu.File.New ");
//$NON-NLS-1$
String newId = ActionFactory.NEW.getId ();
MenuManager newMenu = new MenuManager (newText, newId) {

@Override
public String getMenuText () {
String result = super.getMenuText ();
if (newQuickMenu == null)
return result;
String shortCut = newQuickMenu.getShortCutString ();
if (shortCut == null)
return result;
return result + "\t" + shortCut; //$NON-NLS-1$
}
};
newMenu.add (new Separator (newId));
myNewWizardMenu = new NewWizardMenu (myWindow);
newMenu.add (myNewWizardMenu);
newMenu.add (new Separator
(IWorkbenchActionConstants.MB_ADDITIONS));

return newMenu;
}
--->8---

This set up I got from reading the way the IDE create the file menu based
on a post on this form from last year.

Any ideas or advice would be appreciated.

Thanks,

Ian
SOLVED Re: How do I get my new wizard to show up as special [message #449390 is a reply to message #449091] Thu, 11 May 2006 14:19 Go to previous message
Eclipse UserFriend
Ian Leslie wrote:

> By special I mean in the drop down above the "Other..." item or in the
> "New>" flyout menu before the "Other..." menu item.

> For example in the SDK (mine at least) both places have a list of new
> wizards such as "Prject", "Package", "Class" etc. before the "Other..."
> item in both places. How do I get that for my RCP application.

> I tried specifying my wizard as a primary wizards but (see my previous
> post) that meant my wizard did not appear at all.

I looked at this before by searching out who other wizards appeared where
I wanted mine to. For some reason this time I spotted what I could not
see before. The solution is to create a perspective extension in the
plug-in the declares the new Wizard to make it available on the
perspective or my application thus:

<extension
point="org.eclipse.ui.perspectiveExtensions">
<perspectiveExtension
targetID="com.lesliesoftware.wizardsfamiliar.perspective.design ">
<newWizardShortcut
id=" com.lesliesoftware.wizardsfamiliar.deck.editor.wizards.DeckC reationWizard "/>
</perspectiveExtension>
</extension>
Previous Topic:How to detect if a View has been selected?
Next Topic:How to arrange editors programmatically
Goto Forum:
  


Current Time: Sun Aug 31 04:48:52 EDT 2025

Powered by FUDForum. Page generated in 0.04105 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top