Пример #1
0
 private void btnAddTrait_Click(object sender, EventArgs e)
 {
     Trait newTS = new Trait();
     newTS.name = "newTrait";
     newTS.tag = "newTraitTag_" + prntForm.mod.nextIdNumber.ToString();
     prntForm.traitsList.Add(newTS);
     refreshListBox();
 }
Пример #2
0
 private bool traitExists(Trait itImp)
 {
     foreach (Trait it in prntForm.traitsList)
     {
         if (it.tag == itImp.tag)
         {
             return true;
         }
     }
     return false;
 }