private void Select(PhysicsInstanceDefinition physicsInstanceDefinition)
        {
            RemoveUserControl();

            if (physicsInstanceDefinition.BoundingData.ToLowerInvariant().Contains("halfvalues"))
            {
                m_userControl_physicsInstanceDefinition = new UserControl_PhysicsInstanceDefinition(new PhysicsInstanceDefinition_WithBoundingBox(physicsInstanceDefinition));
            }
            else if (physicsInstanceDefinition.BoundingData.ToLowerInvariant().Contains("radius"))
            {
                m_userControl_physicsInstanceDefinition = new UserControl_PhysicsInstanceDefinition(new PhysicsInstanceDefinition_WithCircle(physicsInstanceDefinition));
            }
            else if (physicsInstanceDefinition.BoundingData.ToLowerInvariant().Contains("characterwidth"))
            {
                m_userControl_physicsInstanceDefinition = new UserControl_PhysicsInstanceDefinition(new PhysicsInstanceDefinition_WithFont(physicsInstanceDefinition));
            }

            m_grid_main.SetRowColumn(m_userControl_physicsInstanceDefinition, 1, 0);
        }
 private void RemoveUserControl()
 {
     if (m_userControl_physicsInstanceDefinition != null)
         m_grid_main.Children.Remove(m_userControl_physicsInstanceDefinition);
     m_userControl_physicsInstanceDefinition = null;
 }
 private void New()
 {
     RemoveUserControl();
     m_userControl_physicsInstanceDefinition = new UserControl_PhysicsInstanceDefinition();
     m_grid_main.SetRowColumn(m_userControl_physicsInstanceDefinition, 1, 0);
 }