Ejemplo n.º 1
0
        ///<summary></summary>
        public ToothGraphicCollection Copy()
        {
            ToothGraphicCollection collect = new ToothGraphicCollection();

            for (int i = 0; i < this.Count; i++)
            {
                collect.Add(this[i].Copy());
            }
            return(collect);
        }
 ///<summary>If ListToothGraphics is empty, then this fills it, including the complex process of loading all drawing points from local resources.  Or if not empty, then this resets all 32+20 teeth to default postitions, no restorations, etc. Primary teeth set to visible false.  Also clears selected.  Should surround with SuspendLayout / ResumeLayout.</summary>
 public void ResetTeeth()
 {
     selectedTeeth = new string[0];
     if (simpleMode)
     {
         if (ListToothGraphics.Count == 0)               //so this will only happen once when program first loads.
         {
             ListToothGraphics.Clear();
             ToothGraphic tooth;
             for (int i = 1; i <= 32; i++)
             {
                 tooth         = new ToothGraphic(i.ToString());
                 tooth.Visible = true;
                 ListToothGraphics.Add(tooth);
                 //primary
                 if (ToothGraphic.PermToPri(i.ToString()) != "")
                 {
                     tooth         = new ToothGraphic(ToothGraphic.PermToPri(i.ToString()));
                     tooth.Visible = false;
                     ListToothGraphics.Add(tooth);
                 }
             }
         }
         else                                                  //list was already initially filled, but now user needs to reset it.
         {
             for (int i = 0; i < ListToothGraphics.Count; i++) //loop through all perm and pri teeth.
             {
                 ListToothGraphics[i].Reset();
             }
         }
         ALSelectedTeeth.Clear();
         selectedTeeth = new string[0];
         this.Invalidate();
     }
     else
     {
         toothChart.ResetTeeth();
     }
 }
Ejemplo n.º 3
0
		///<summary></summary>
		public ToothGraphicCollection Copy() {
			ToothGraphicCollection collect=new ToothGraphicCollection();
			for(int i=0;i<this.Count;i++) {
				collect.Add(this[i].Copy());
			}
			return collect;
		}