private void editProperties(object sauce, EventArgs args) { TreeIter i; TreeModel m; if (projectsTreeview.Selection.GetSelected(out m, out i)) { int val = (int)m.GetValue(i, 2); Project p = (Project)this.projects.ToArray()[val]; ProjectWindow pw = new ProjectWindow(p); pw.OnProjectChanged += ProjectWindowHidden; pw.Show(); } }
private void newProject(object source, EventArgs args) { Project p = new Project(); p.StartPolling(); ProjectWindow pw = new ProjectWindow(p); pw.OnProjectChanged += ProjectWindowHidden; p.OnPolled += new PolledEventHandler(ProjectPolled); p.OnPolled += new PolledEventHandler(this.icon.ProjectPolled); p.OnBuildOccurred += new BuildOccurredEventHandler(this.icon.BuildOccurred); pw.Show(); this.projects.Add(p); UpdateProjectList(); }