Skip to content

Commit

Permalink
Set default project type
Browse files Browse the repository at this point in the history
  • Loading branch information
lincolnthree committed Mar 27, 2013
1 parent 7e858e0 commit 968f6fa
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -121,10 +121,11 @@ public String convert(ProjectType source)
List<ProjectType> projectTypes = new ArrayList<ProjectType>();
for (ExportedInstance<ProjectType> instance : registry.getExportedInstances(ProjectType.class))
{
projectTypes.add(instance.get());
ProjectType projectType = instance.get();
projectTypes.add(projectType);
type.setDefaultValue(projectType);
}
type.setValueChoices(projectTypes);

builder.add(named).add(topLevelPackage).add(targetLocation).add(overwrite).add(type);
}

Expand Down

3 comments on commit 968f6fa

@gastaldi
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a reason to select the last project type as the default or just because any default must be set ?

@gastaldi
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Btw, the ordering of these project types are undefined. They change on each invocation

@lincolnthree
Copy link
Member Author

@lincolnthree lincolnthree commented on 968f6fa Mar 27, 2013 via email

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.