public MSBuildBasedProject FindProject(string name)
 {
     foreach (IProject project in projectService.GetOpenProjects())
     {
         if (IsProjectNameMatch(project.Name, name))
         {
             return(project as MSBuildBasedProject);
         }
     }
     return(null);
 }
Esempio n. 2
0
        void SolutionLoaded(object sender, EventArgs e)
        {
            solution = projectService.OpenSolution;
            solution.ProjectAdded += ProjectAdded;
            projects = projectService.GetOpenProjects().ToList();

            foreach (IDotNetProject project in projects)
            {
                project.Modified += ProjectModified;
            }
        }
 public IDotNetProject FindProject(string name)
 {
     foreach (IProject project in projectService.GetOpenProjects())
     {
         if (IsProjectNameMatch(project, name))
         {
             return(project as IDotNetProject);
         }
     }
     return(null);
 }
        public void RegisterConsole(IScriptingConsole console)
        {
            packageManagementConsole = console;

            IdeApp.Workspace.SolutionLoaded          += SolutionLoaded;
            IdeApp.Workspace.SolutionUnloaded        += SolutionUnloaded;
            IdeApp.Workspace.ItemAddedToSolution     += ProjectsChangedInSolution;
            IdeApp.Workspace.ItemRemovedFromSolution += ProjectsChangedInSolution;
            projects = new ObservableCollection <Project> (projectService.GetOpenProjects().Select(p => p.DotNetProject));

            CreateCommands();
            UpdatePackageSourceViewModels();
            UpdateDefaultProject();
            InitConsoleHost();
        }
Esempio n. 5
0
 public IEnumerable <Project> GetDotNetProjects()
 {
     return(projectService.GetOpenProjects());
 }
Esempio n. 6
0
 MSBuildBasedProject FindProject(string uniqueName)
 {
     return(projectService
            .GetOpenProjects()
            .SingleOrDefault(project => ProjectUniqueNameMatches(project, uniqueName)) as MSBuildBasedProject);
 }
Esempio n. 7
0
 IEnumerable <SD.IProject> GetOpenMSBuildProjects()
 {
     return(projectService.GetOpenProjects());
 }
 public IEnumerable <IProject> GetMSBuildProjects()
 {
     return(projectService.GetOpenProjects());
 }