LabWork04 #6
15
solution/lab1/CollectionGenericObjects/ClassForDop.cs
Normal file
15
solution/lab1/CollectionGenericObjects/ClassForDop.cs
Normal file
@ -0,0 +1,15 @@
|
||||
using lab1.Drawnings;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace lab1.CollectionGenericObjects
|
||||
{
|
||||
internal class ClassForDoppublic<T>
|
||||
where T : DrawningTrackedVehicle
|
||||
{
|
||||
|
||||
}
|
||||
}
|
@ -31,20 +31,20 @@ public class DrawningEntityFighter : DrawningTrackedVehicle
|
||||
Brush CraneBrush = new SolidBrush(fighter.AdditionalColor);
|
||||
|
||||
|
||||
|
||||
base.DrawTransport(g);
|
||||
|
||||
|
||||
if (fighter.Kovsh)
|
||||
{
|
||||
|
||||
//ковш
|
||||
///ковш
|
||||
g.DrawRectangle(pen, _startPosX.Value - 2, _startPosY.Value + 37, 8, 15);
|
||||
g.FillRectangle(CraneBrush, _startPosX.Value - 2, _startPosY.Value + 37, 8, 15);
|
||||
g.DrawRectangle(pen, _startPosX.Value - -6, _startPosY.Value + 37, 4, 1);
|
||||
|
||||
}
|
||||
|
||||
//противовес
|
||||
///противовес
|
||||
if (fighter.Otval)
|
||||
{
|
||||
g.DrawRectangle(pen, _startPosX.Value + 73, _startPosY.Value + 37, 17, 1);
|
||||
|
@ -60,9 +60,9 @@
|
||||
groupBoxTools.Controls.Add(panelStorage);
|
||||
groupBoxTools.Controls.Add(comboBoxSelectorCompany);
|
||||
groupBoxTools.Dock = DockStyle.Right;
|
||||
groupBoxTools.Location = new Point(670, 0);
|
||||
groupBoxTools.Location = new Point(635, 0);
|
||||
groupBoxTools.Name = "groupBoxTools";
|
||||
groupBoxTools.Size = new Size(297, 617);
|
||||
groupBoxTools.Size = new Size(297, 615);
|
||||
groupBoxTools.TabIndex = 0;
|
||||
groupBoxTools.TabStop = false;
|
||||
groupBoxTools.Text = "Инструменты";
|
||||
@ -84,20 +84,20 @@
|
||||
// buttonAddFighter
|
||||
//
|
||||
buttonAddFighter.Anchor = AnchorStyles.Top | AnchorStyles.Left | AnchorStyles.Right;
|
||||
buttonAddFighter.Location = new Point(6, 0);
|
||||
buttonAddFighter.Location = new Point(6, 59);
|
||||
buttonAddFighter.Name = "buttonAddFighter";
|
||||
buttonAddFighter.Size = new Size(273, 52);
|
||||
buttonAddFighter.Size = new Size(273, 59);
|
||||
buttonAddFighter.TabIndex = 2;
|
||||
buttonAddFighter.Text = "Добавление истребителя";
|
||||
buttonAddFighter.Text = "Добавление гусеничной машины с оборудованием";
|
||||
buttonAddFighter.UseVisualStyleBackColor = true;
|
||||
buttonAddFighter.Click += ButtonAddTrackedVehicle_Click;
|
||||
buttonAddFighter.Click += ButtonAddFighter_Click;
|
||||
//
|
||||
// buttonAddTrackedVehicle
|
||||
//
|
||||
buttonAddTrackedVehicle.Anchor = AnchorStyles.Top | AnchorStyles.Left | AnchorStyles.Right;
|
||||
buttonAddTrackedVehicle.Location = new Point(6, 58);
|
||||
buttonAddTrackedVehicle.Location = new Point(6, 0);
|
||||
buttonAddTrackedVehicle.Name = "buttonAddTrackedVehicle";
|
||||
buttonAddTrackedVehicle.Size = new Size(273, 60);
|
||||
buttonAddTrackedVehicle.Size = new Size(273, 63);
|
||||
buttonAddTrackedVehicle.TabIndex = 3;
|
||||
buttonAddTrackedVehicle.Text = "Добавление гусеничной машины";
|
||||
buttonAddTrackedVehicle.UseVisualStyleBackColor = true;
|
||||
@ -256,7 +256,7 @@
|
||||
pictureBox.Dock = DockStyle.Fill;
|
||||
pictureBox.Location = new Point(0, 0);
|
||||
pictureBox.Name = "pictureBox";
|
||||
pictureBox.Size = new Size(670, 617);
|
||||
pictureBox.Size = new Size(635, 615);
|
||||
pictureBox.TabIndex = 1;
|
||||
pictureBox.TabStop = false;
|
||||
pictureBox.Click += pictureBox1_Click;
|
||||
@ -265,7 +265,7 @@
|
||||
//
|
||||
AutoScaleDimensions = new SizeF(10F, 25F);
|
||||
AutoScaleMode = AutoScaleMode.Font;
|
||||
ClientSize = new Size(967, 617);
|
||||
ClientSize = new Size(932, 615);
|
||||
Controls.Add(pictureBox);
|
||||
Controls.Add(groupBoxTools);
|
||||
Name = "FormTrackedVehicleCollection";
|
||||
|
@ -47,7 +47,7 @@ public partial class FormTrackedVehicleCollection : Form
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
private void ButtonAddEntityFighter_Click(object sender, EventArgs e) => CreateObject(nameof(DrawningEntityFighter));
|
||||
private void ButtonAddFighter_Click(object sender, EventArgs e) => CreateObject(nameof(DrawningEntityFighter));
|
||||
|
||||
/// <summary>
|
||||
/// Создание объекта класса-перемещения
|
||||
|
Loading…
Reference in New Issue
Block a user