public virtual bool TapDCG(DCGElement nearestElement)
 {
     if (nearestElement == null)
     {
         return(false);
     }
     if (nearestElement.ParentSelected())
     {
         return(false);
     }
     if (nearestElement != null && !nearestElement.isLocked)
     {
         List <Point> newSel = Select(nearestElement);
         DeselectChildren(nearestElement);
         DCGBase.sElements.Remove(nearestElement);
         DCGBase.sElements.Add(nearestElement);
         foreach (Point p in newSel)
         {
             DCGBase.sPoints.Remove(p); //If the point exists in the point list, remove the copy before adding it in
             DCGBase.sPoints.Add(p);
         }
         if (nearestElement.GetType() != typeof(Solid))
         {
             List <DCGElement> elems = nearestElement.GetParents();
             foreach (DCGElement elem in elems)
             {
                 TapDCG(elem);
             }
         }
         else
         {
             Solid s = (Solid)nearestElement;
             s.addPointsToDCG();
         }
         return(true);
     }
     else
     {
         return(false);
     }
 }
 public override bool TapDCG(DCGElement nearestElement)
 {
     if (nearestElement.ParentSelected())
     {
         return(false);
     }
     if (nearestElement != null && !nearestElement.isLocked)
     {
         List <Point> newSel = Select(nearestElement);
         DCGBase.sElements.Remove(nearestElement);
         DCGBase.sElements.Add(nearestElement);
         foreach (Point p in newSel)
         {
             DCGBase.sPoints.Remove(p); //If the point exists in the point list, remove the copy before adding it in
             DCGBase.sPoints.Add(p);
         }
         return(true);
     }
     else
     {
         return(false);
     }
 }