public void Execute(ICommandId commandId, object parameter) { if (commandId == null || commandId.GroupId != NuGetCommands.GroupId) { return; } if (commandId == NuGetCommands.OpenNuGetGalleryCommandId) { this.OpenNuGetGallery(); } }
public CommandStatus CanExecute(ICommandId commandId, object parameter) { if (commandId == null || commandId.GroupId != NuGetCommands.GroupId) { return CommandStatus.UnSupported; } if (commandId == NuGetCommands.OpenNuGetGalleryCommandId) { return CommandStatus.EnabledAndSupported; } else { Debug.Fail("Unknown CommandId detected."); return CommandStatus.UnSupported; } }
public CommandStatus CanExecute(ICommandId commandId, object parameter) { if (commandId == null || commandId.GroupId != NuGetCommands.GroupId) { return(CommandStatus.UnSupported); } if (commandId == NuGetCommands.OpenNuGetGalleryCommandId) { return(CommandStatus.EnabledAndSupported); } else { Debug.Fail("Unknown CommandId detected."); return(CommandStatus.UnSupported); } }