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 Gual <lluis@xamarin.com>2015-04-22 12:20:34 +0300
committerLluis Sanchez Gual <lluis@xamarin.com>2015-04-22 12:20:34 +0300
commit8ebc2e3392d31438ae3cd17ac12031edfd76bcf6 (patch)
treeb6eab7b52aa9662caf0206d9970b91b812e687d5
parenta8f962bb4f0ecf7c7e2e6c94eee3dc6be5bf78bf (diff)
[Core] Add new overridable to Project
Added method for checking if a build action is a compilation build action.
-rw-r--r--main/src/core/MonoDevelop.Core/MonoDevelop.Projects/Project.cs20
-rw-r--r--main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectExtension.cs5
2 files changed, 25 insertions, 0 deletions
diff --git a/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/Project.cs b/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/Project.cs
index 918762f797..efa8b59602 100644
--- a/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/Project.cs
+++ b/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/Project.cs
@@ -366,6 +366,21 @@ namespace MonoDevelop.Projects
}
/// <summary>
+ /// Determines whether the provided build action is a compile action
+ /// </summary>
+ /// <returns><c>true</c> if this instance is compile build action the specified buildAction; otherwise, <c>false</c>.</returns>
+ /// <param name="buildAction">Build action.</param>
+ public bool IsCompileBuildAction (string buildAction)
+ {
+ return ProjectExtension.OnGetIsCompileBuildAction (buildAction);
+ }
+
+ protected virtual bool OnGetIsCompileBuildAction (string buildAction)
+ {
+ return buildAction == BuildAction.Compile;
+ }
+
+ /// <summary>
/// Files of the project
/// </summary>
public ProjectFileCollection Files {
@@ -2435,6 +2450,11 @@ namespace MonoDevelop.Projects
return Project.OnGetIsCompileable (fileName);
}
+ internal protected override bool OnGetIsCompileBuildAction (string buildAction)
+ {
+ return Project.OnGetIsCompileBuildAction (buildAction);
+ }
+
internal protected override void OnGetTypeTags (HashSet<string> types)
{
Project.OnGetTypeTags (types);
diff --git a/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectExtension.cs b/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectExtension.cs
index cd8d3d4a75..83f0dbb5ea 100644
--- a/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectExtension.cs
+++ b/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectExtension.cs
@@ -127,6 +127,11 @@ namespace MonoDevelop.Projects
return next.OnGetIsCompileable (fileName);
}
+ internal protected virtual bool OnGetIsCompileBuildAction (string buildAction)
+ {
+ return next.OnGetIsCompileBuildAction (buildAction);
+ }
+
internal protected virtual string OnGetDefaultBuildAction (string fileName)
{
return next.OnGetDefaultBuildAction (fileName);