Esempio n. 1
0
File: Scene.cs Progetto: AtanasK/VP
 public Scene()
 {
     shapes = new List<Shape>();
     CurrentColor = Color.Red;
     selectedShape = null;
 }
Esempio n. 2
0
File: Scene.cs Progetto: AtanasK/VP
 // On mouse up
 public void ClearSelected()
 {
     selectedShape.Selected = false;
     selectedShape = null;
 }
Esempio n. 3
0
File: Scene.cs Progetto: AtanasK/VP
 // On mouse down
 public void Select(Point position)
 {
     foreach (Shape shape in shapes)
     {
         if (shape.Clicked(position))
         {
             selectedShape = shape;
             selectedShape.Selected = true;
         }
     }
     previousPoint = position;
 }