Лабораторная работа№5
This commit is contained in:
parent
d5fc3fd5ec
commit
b8f9419775
@ -1,16 +0,0 @@
|
|||||||
using ProjectAirFighter.Drawning;
|
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Reflection.Metadata.Ecma335;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace ProjectAirFighter;
|
|
||||||
|
|
||||||
public class AdNum<T>
|
|
||||||
where T : DrawningAirFighter
|
|
||||||
{
|
|
||||||
public void Nothing(){
|
|
||||||
}
|
|
||||||
}
|
|
@ -4,21 +4,6 @@
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public class EntityAirFighter : EntityWarPlane
|
public class EntityAirFighter : EntityWarPlane
|
||||||
{
|
{
|
||||||
/// <summary>
|
|
||||||
/// Скорость
|
|
||||||
/// </summary>
|
|
||||||
public int Speed { get; private set; }
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Вес
|
|
||||||
/// </summary>
|
|
||||||
public double Weight { get; private set; }
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Основной цвет
|
|
||||||
/// </summary>
|
|
||||||
public Color BodyColor { get; private set; }
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Дополнительный цвет
|
/// Дополнительный цвет
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
@ -156,10 +156,13 @@ public partial class FormWarPlaneConfig : Form
|
|||||||
}
|
}
|
||||||
private void labelAdditionalColor_DragEnter(object sender, DragEventArgs e)
|
private void labelAdditionalColor_DragEnter(object sender, DragEventArgs e)
|
||||||
{
|
{
|
||||||
if (e.Data.GetDataPresent(typeof(Color)))
|
if (_warPlane?.EntityWarPlane is EntityAirFighter _airFighter)
|
||||||
e.Effect = DragDropEffects.Copy;
|
{
|
||||||
else
|
if (e.Data.GetDataPresent(typeof(Color)))
|
||||||
e.Effect = DragDropEffects.None;
|
e.Effect = DragDropEffects.Copy;
|
||||||
|
else
|
||||||
|
e.Effect = DragDropEffects.None;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private void buttonAdd_Click(object sender, EventArgs e)
|
private void buttonAdd_Click(object sender, EventArgs e)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user