diff options
author | nosami <jasonimison@gmail.com> | 2019-10-09 22:10:17 +0300 |
---|---|---|
committer | nosami <jasonimison@gmail.com> | 2019-10-10 21:02:50 +0300 |
commit | a883331b49c67593999d707a901555a076b72c3e (patch) | |
tree | 8f274009531f814d9bce1f3e9b553b810467e17d /main/src/addins/MonoDevelop.DotNetCore | |
parent | 5ad94094d624228f48e6f11da0497937b8800b6b (diff) |
Hide command as well as disable for non SDK projects
Diffstat (limited to 'main/src/addins/MonoDevelop.DotNetCore')
-rw-r--r-- | main/src/addins/MonoDevelop.DotNetCore/MonoDevelop.DotNetCore.Commands/PackCommandHandler.cs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/main/src/addins/MonoDevelop.DotNetCore/MonoDevelop.DotNetCore.Commands/PackCommandHandler.cs b/main/src/addins/MonoDevelop.DotNetCore/MonoDevelop.DotNetCore.Commands/PackCommandHandler.cs index f34724202b..6d94a35a54 100644 --- a/main/src/addins/MonoDevelop.DotNetCore/MonoDevelop.DotNetCore.Commands/PackCommandHandler.cs +++ b/main/src/addins/MonoDevelop.DotNetCore/MonoDevelop.DotNetCore.Commands/PackCommandHandler.cs @@ -13,18 +13,18 @@ namespace MonoDevelop.DotNetCore.Commands { protected override void Run (object dataItem) { - var project = IdeApp.ProjectOperations.CurrentSelectedProject as DotNetProject; - if (project == null) - return; + var project = IdeApp.ProjectOperations.CurrentSelectedProject as DotNetProject; + if (project == null) + return; - var buildTarget = new PackProjectBuildTarget (project); - IdeApp.ProjectOperations.Build (buildTarget); + var buildTarget = new PackProjectBuildTarget (project); + IdeApp.ProjectOperations.Build (buildTarget); } protected override void Update (CommandInfo info) { var project = IdeApp.ProjectOperations.CurrentSelectedProject as DotNetProject; - info.Enabled = project != null && IsDotNetCoreProject(project); + info.Enabled = info.Visible = project != null && IsDotNetCoreProject (project); } bool IsDotNetCoreProject (Project project)
|