public Scene() { shapes = new List<Shape>(); CurrentColor = Color.Red; selectedShape = null; }
// On mouse up public void ClearSelected() { selectedShape.Selected = false; selectedShape = null; }
// On mouse down public void Select(Point position) { foreach (Shape shape in shapes) { if (shape.Clicked(position)) { selectedShape = shape; selectedShape.Selected = true; } } previousPoint = position; }