Search in sources :

Example 1 with ProjectJdkStep

use of com.intellij.ide.util.projectWizard.ProjectJdkStep in project intellij-community by JetBrains.

the class JavaProjectStructureDetector method createWizardSteps.

@Override
public List<ModuleWizardStep> createWizardSteps(ProjectFromSourcesBuilder builder, ProjectDescriptor projectDescriptor, Icon stepIcon) {
    final List<ModuleWizardStep> steps = new ArrayList<>();
    final ModuleInsight moduleInsight = new JavaModuleInsight(new DelegatingProgressIndicator(), builder.getExistingModuleNames(), builder.getExistingProjectLibraryNames());
    steps.add(new LibrariesDetectionStep(builder, projectDescriptor, moduleInsight, stepIcon, "reference.dialogs.new.project.fromCode.page1"));
    steps.add(new ModulesDetectionStep(this, builder, projectDescriptor, moduleInsight, stepIcon, "reference.dialogs.new.project.fromCode.page2"));
    if (builder.getContext().isCreatingNewProject()) {
        final ModuleWizardStep jdkStep = ProjectWizardStepFactory.getInstance().createProjectJdkStep(builder.getContext());
        steps.add(jdkStep);
        if (jdkStep instanceof ProjectJdkStep) {
            ((ProjectJdkStep) jdkStep).setProjectDescriptor(projectDescriptor);
        }
    }
    return steps;
}
Also used : DelegatingProgressIndicator(com.intellij.ide.util.DelegatingProgressIndicator) ProjectJdkStep(com.intellij.ide.util.projectWizard.ProjectJdkStep) ModuleWizardStep(com.intellij.ide.util.projectWizard.ModuleWizardStep) ArrayList(java.util.ArrayList)

Aggregations

DelegatingProgressIndicator (com.intellij.ide.util.DelegatingProgressIndicator)1 ModuleWizardStep (com.intellij.ide.util.projectWizard.ModuleWizardStep)1 ProjectJdkStep (com.intellij.ide.util.projectWizard.ProjectJdkStep)1 ArrayList (java.util.ArrayList)1