After we create a new project in eclipse, a dialog will be showed as following picture if our current perspective is not associated with this kind of project. So how do Eclipse make this programmatically?
I think it depends on the project nature but the perspective extension point
has nothing to connect with the project nature.
Tks for your time :-)
You have to set the finalPerspective
attribute in your wizard. See
Associating a Wizard with a Perspective for reference:
Add the finalPerspective
attribute to the definition of our wizard element in the extension.
Make the Wizard class implement the interface IExecutableExtension
. This interface has only one method setInitializationData
. Implement the method in the class and assign the parameter IConfigurationElement
to a field in the method.
In the performFinish
method of the Wizard, call BasicNewProjectResourceWizard.updatePerspective
method.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With