private void BuildSubtreeForTarget(BuildTargetObject target)
 {
     TreeNode targetNode =  tvBuildSequence.Nodes[0].Nodes.Add(target.Name);
     targetNode.Tag = target;
     foreach (BuildTask buildTask in target.BuildTasks) {
         TreeNode taskNode = targetNode.Nodes.Add(buildTask.GetTextRepresentation());
         taskNode.Tag = buildTask;
     }
 }
 private void TargetToolStripMenuItemClick(object sender, EventArgs e)
 {
     try {
         AddTargetForm form = new AddTargetForm(availableTargets);
         DialogResult dial = form.ShowDialog();
         if (dial == DialogResult.OK) {
             BuildTargetObject buildTarget = new BuildTargetObject(form.buildTargetName,new List<BuildTask>());
             availableTargets.Add(buildTarget);
         }
     } catch (Exception ex) {
         CommonUtils.ShowError(ex.Message,ex);
     }
 }
 private void BuildGeneratorFormLoad(object sender, EventArgs e)
 {
     try {
         base.LoadForm(this);
         txtEditorBText.SetHighlighting("XML");
         //FillAvailableTasks();
         //FIXME: add properties categories and build task categories here
         BuildTask selectedBuildTask = new BuildTask(0,"automation.comparisonguixml"
                 ,"http://globalqa/qa/infrastructure/doc/runtime/v2.3/AutoAntTasks/AutoAntCompareTableGeneric.html"
                 ,(int)ApplicationEnumerations.BuildTaskCat.Default,1,DateTime.Now,4,DateTime.Now.AddDays(3));
         selectedBuildTask.TaskProperties.Add( new BuildTaskProperty("ReachedDocument","${datastore}.screen.reached.xml",1, false,8,DateTime.Now));
         selectedBuildTask.TaskProperties.Add( new BuildTaskProperty("ReachedGimDocument","",1, true,8,DateTime.Now));
         selectedBuildTask.TaskProperties.Add( new BuildTaskProperty("ExpectedDocument","",1, true,8,DateTime.Now));
         selectedBuildTask.TaskProperties.Add( new BuildTaskProperty("ExpectedGimDocument","",1, false,8,DateTime.Now));
         selectedBuildTask.TaskProperties.Add( new BuildTaskProperty("ReachedGimFile","",1, false,8,DateTime.Now));
         selectedBuildTask.TaskProperties.Add( new BuildTaskProperty("ExpectedFile","",1, false,8,DateTime.Now));
         selectedBuildTask.TaskProperties.Add( new BuildTaskProperty("ExpectedGimFile","",1, false,8,DateTime.Now));
         selectedBuildTask.TaskProperties.Add( new BuildTaskProperty("Customs","",1, false,8,DateTime.Now));
         selectedBuildTask.TaskProperties.Add( new BuildTaskProperty("Fast","False",1, false,8,DateTime.Now));
         selectedBuildTask.TaskProperties.Add( new BuildTaskProperty("doCompare","True",1, false,8,DateTime.Now));
         selectedBuildTask.TaskProperties.Add( new BuildTaskProperty("doColor","True",1, false,8,DateTime.Now));
         selectedBuildTask.TaskProperties.Add( new BuildTaskProperty(0,"name","",(int)ApplicationEnumerations.PropertyType.ConfigFileNested,true,"configFileTemplate",1,8,DateTime.Now,8,DateTime.Now));
         ListViewItem item = lvAvailableTasks.Items.Add(selectedBuildTask.Name);
         item.Tag = selectedBuildTask;
         TreeNode projectNode =  tvBuildSequence.Nodes.Add("projectDefRun","project default=\"run\"");
         BuildTargetObject buildTarget = new BuildTargetObject("Run",new List<BuildTask>());
         availableTargets.Add(buildTarget);
         TreeNode targetNode =projectNode.Nodes.Add(buildTarget.Name);
         targetNode.Tag = buildTarget;
     } catch (Exception ex) {
         CommonUtils.ShowError(ex.Message,ex);
     }
 }