Принято

This commit is contained in:
Владимир Данилов 2023-12-02 23:53:20 +04:00
parent 841f064d03
commit fac6bdd215
2 changed files with 2 additions and 17 deletions

View File

@ -21,7 +21,7 @@ namespace Project_DumpTruck
/// <summary> /// <summary>
/// Событие /// Событие
/// </summary> /// </summary>
private event TruckDelegate? EventAddTruck; private event Action<DrawningTruck> EventAddTruck;
/// <summary> /// <summary>
/// Конструктор /// Конструктор
/// </summary> /// </summary>
@ -56,7 +56,7 @@ namespace Project_DumpTruck
/// Добавление события /// Добавление события
/// </summary> /// </summary>
/// <param name="ev">Привязанный метод</param> /// <param name="ev">Привязанный метод</param>
public void AddEvent(TruckDelegate ev) public void AddEvent(Action<DrawningTruck> ev)
{ {
if (EventAddTruck == null) if (EventAddTruck == null)
{ {

View File

@ -1,15 +0,0 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Project_DumpTruck.DrawningObjects;
namespace Project_DumpTruck
{
/// <summary>
/// Делегат для передачи объекта-автомобиля
/// </summary>
/// <param name="car"></param>
public delegate void TruckDelegate(DrawningTruck Truck);
}