Ejemplo n.º 1
0
 void loadData(m_Detection d)
 {
     d.name     = textBox1.Text;
     d.loop     = checkLoop.IsChecked.Value;
     d.priority = checkPrior.IsChecked.Value;
     d.expand   = true;
 }
Ejemplo n.º 2
0
 public void editDetection(m_Detection d_origin)
 {
     addNew               = false;
     this.Title           = "Edit Detection";
     butAdd.Content       = "Edit";
     this.d_origin        = d_origin;
     textBox1.Text        = d_origin.name;
     checkLoop.IsChecked  = d_origin.loop;
     checkPrior.IsChecked = d_origin.priority;
 }
Ejemplo n.º 3
0
 void finish()
 {
     try
     {
         String name = textBox1.Text;
         if (name != "")
         {
             if (addNew)
             {
                 m_Detection d = new m_Detection();
                 loadData(d);
                 form_editor.addDetection(d, addIndex);
             }
             else
             {
                 int[] loc = form_editor.getTVI_Location(self);
                 loadData(d_origin);
                 form_editor.reloadTree_map_map(loc);
             }
             this.Close();
         }
     }
     catch { }
 }