Handle wizard's navigation (Next > and < Back buttons) [message #213705] |
Mon, 04 June 2007 14:22  |
Eclipse User |
|
|
|
Originally posted by: g_boivin_dufault.hotmail.com
Hi,
I wrote a similar post a week ago but couldn't have any answers so I'll
try to make it clearer. Inside a new Plug In project, I've created a
NewWizard extension. The referenced class extends the
org.eclipse.jface.wizard.Wizard abstract class and implements the
org.eclipse.ui.INewWizard interface. My Wizard uses two WizardPage.
When the first page is filled and the user clicks Next, I would like to
make an action (create a new project Resource). At the second page, if the
user clicks Back, I also want to make an action (delete the newly added
project Resource).
Basically, what I want to reproduce is the same functionality as the "New
Java Project" Eclipse wizard. When you enter a project's name in the
"Create a Java Project" wizard's page and click on the next button, the
project's resource is added to the package explorer view and the project's
description files are generated. In the opposite situation, when the
user's at the "Java Settings" wizard's page and clicks on the Back button,
all the previous operations are undone, the project is deleted from the
package explorer view as in the OS file structure.
In other words, how can I know that the next/back button have been
clicked? I know that by extending the Wizard class, I can override the
getNextPage() method but that's not what I'm looking for. I'm searching
for an option more like : next_button.addListener(new
NextButtonListener()), back_button.addListener(new BackButtonListener())...
Thanks in advance,
Guillaume Boivin-Dufault
|
|
|
|
Re: Handle wizard's navigation (Next > and < Back buttons) [message #213850 is a reply to message #213705] |
Tue, 05 June 2007 03:23  |
Eclipse User |
|
|
|
Originally posted by: jakub.jurkiewicz.gmail.com
Hi,
You can try to check how it is done in the Eclipse itself. Just look at
the Eclipse's sources in the CVS.
--
Jakub Jurkiewicz
http://eclipser-blog.blogspot.com/
Guillaume Boivin-Dufault wrote::
> Hi, I wrote a similar post a week ago but couldn't have any answers so
> I'll try to make it clearer. Inside a new Plug In project, I've created
> a NewWizard extension. The referenced class extends the
> org.eclipse.jface.wizard.Wizard abstract class and implements the
> org.eclipse.ui.INewWizard interface. My Wizard uses two WizardPage.
> When the first page is filled and the user clicks Next, I would like to
> make an action (create a new project Resource). At the second page, if
> the user clicks Back, I also want to make an action (delete the newly
> added project Resource).
> Basically, what I want to reproduce is the same functionality as the
> "New Java Project" Eclipse wizard. When you enter a project's name in
> the "Create a Java Project" wizard's page and click on the next button,
> the project's resource is added to the package explorer view and the
> project's description files are generated. In the opposite situation,
> when the user's at the "Java Settings" wizard's page and clicks on the
> Back button, all the previous operations are undone, the project is
> deleted from the package explorer view as in the OS file structure.
>
> In other words, how can I know that the next/back button have been
> clicked? I know that by extending the Wizard class, I can override the
> getNextPage() method but that's not what I'm looking for. I'm searching
> for an option more like : next_button.addListener(new
> NextButtonListener()), back_button.addListener(new BackButtonListener())...
>
> Thanks in advance,
>
> Guillaume Boivin-Dufault
>
|
|
|
Powered by
FUDForum. Page generated in 0.07743 seconds