Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/monodevelop.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLluis Sanchez <lluis@xamarin.com>2014-03-12 14:34:38 +0400
committerLluis Sanchez <lluis@xamarin.com>2014-03-12 14:35:53 +0400
commitcce264cbf1004be5fcdce567b6e4dde706669cd5 (patch)
tree8057c076db80cdf35739f37105977c93ca4d33c6 /main/src/core/MonoDevelop.Core
parentd206518617906021e74e51a0db68cfcd095252f1 (diff)
[Ide] Project creation fix
Don't crash if a project type is not supported when creating a solution, just ignore the project.
Diffstat (limited to 'main/src/core/MonoDevelop.Core')
-rw-r--r--main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectService.cs9
1 files changed, 9 insertions, 0 deletions
diff --git a/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectService.cs b/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectService.cs
index b4bcdf9abb..a5aa5415c6 100644
--- a/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectService.cs
+++ b/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectService.cs
@@ -502,6 +502,15 @@ namespace MonoDevelop.Projects
throw new InvalidOperationException ("Project type '" + type + "' not found");
}
+ public bool CanCreateProject (string type)
+ {
+ foreach (ProjectBindingCodon projectBinding in projectBindings) {
+ if (projectBinding.ProjectBinding.Name == type)
+ return true;
+ }
+ return false;
+ }
+
//TODO: find solution that contains the project if possible
public Solution GetWrapperSolution (IProgressMonitor monitor, string filename)
{