Example #1
0
        public void ClearTest()
        {
            var editData  = Mock.Create <EditData>(Constructor.Mocked);
            var deleteFig = new ClearCanva(new List <Figure>(), new List <Figure>());

            editData.Clear(deleteFig);
            Mock.Assert(() => editData.Clear(deleteFig), Occurs.AtLeastOnce());
        }
Example #2
0
 /// <summary>
 /// Метод, выполняющий очистку канвы.
 /// </summary>
 public void DeleteFigure()
 {
     if (_points.Count != 0)
     {
         _points.Clear();
     }
     _clearCanva = UnityContainerInit.Resolve <ClearCanva>(new OrderedParametersOverride(new object[] { _drawOnCanvas.FiguresList, _listFigure }));
     _editData.Clear(_clearCanva);
     _selectClass.MouseUp();
 }
Example #3
0
        /// <summary>
        /// Метод, очищающий список с фигурами.
        /// </summary>
        public void Clear(ClearCanva clearCanva)
        {
            if (_drawClass.FiguresList.Count == 0)
            {
                _drawClass.EditFigure();

                _listIFigures[0] = clearCanva;
                _actions.AddAction(_listIFigures);
            }
        }