Compare commits
2 Commits
b9b569f60f
...
d639cbd1cc
Author | SHA1 | Date | |
---|---|---|---|
d639cbd1cc | |||
4ad2966f9d |
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,24 +31,24 @@ public class DrawningEntityFighter : DrawningTrackedVehicle
|
|||||||
Brush CraneBrush = new SolidBrush(fighter.AdditionalColor);
|
Brush CraneBrush = new SolidBrush(fighter.AdditionalColor);
|
||||||
|
|
||||||
|
|
||||||
|
base.DrawTransport(g);
|
||||||
|
|
||||||
|
|
||||||
if (fighter.Kovsh)
|
if (fighter.Kovsh)
|
||||||
{
|
{
|
||||||
|
|
||||||
//ковш
|
///ковш
|
||||||
g.DrawRectangle(pen, _startPosX.Value - 2, _startPosY.Value + 37, 8, 15);
|
g.DrawRectangle(pen, _startPosX.Value - 17, _startPosY.Value + 12, 8, 15);
|
||||||
g.FillRectangle(CraneBrush, _startPosX.Value - 2, _startPosY.Value + 37, 8, 15);
|
g.FillRectangle(CraneBrush, _startPosX.Value - 17, _startPosY.Value + 12, 8, 15);
|
||||||
g.DrawRectangle(pen, _startPosX.Value - -6, _startPosY.Value + 37, 4, 1);
|
g.DrawRectangle(pen, _startPosX.Value - 8, _startPosY.Value + 17, 5, 1);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//противовес
|
///противовес
|
||||||
if (fighter.Otval)
|
if (fighter.Otval)
|
||||||
{
|
{
|
||||||
g.DrawRectangle(pen, _startPosX.Value + 73, _startPosY.Value + 37, 17, 1);
|
g.DrawRectangle(pen, _startPosX.Value + 63, _startPosY.Value + 17, 17, 1);
|
||||||
g.DrawRectangle(pen, _startPosX.Value + 90, _startPosY.Value + 37, 1, 17);
|
g.DrawRectangle(pen, _startPosX.Value + 80, _startPosY.Value + 17, 1, 16);
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -60,9 +60,9 @@
|
|||||||
groupBoxTools.Controls.Add(panelStorage);
|
groupBoxTools.Controls.Add(panelStorage);
|
||||||
groupBoxTools.Controls.Add(comboBoxSelectorCompany);
|
groupBoxTools.Controls.Add(comboBoxSelectorCompany);
|
||||||
groupBoxTools.Dock = DockStyle.Right;
|
groupBoxTools.Dock = DockStyle.Right;
|
||||||
groupBoxTools.Location = new Point(670, 0);
|
groupBoxTools.Location = new Point(635, 0);
|
||||||
groupBoxTools.Name = "groupBoxTools";
|
groupBoxTools.Name = "groupBoxTools";
|
||||||
groupBoxTools.Size = new Size(297, 617);
|
groupBoxTools.Size = new Size(297, 615);
|
||||||
groupBoxTools.TabIndex = 0;
|
groupBoxTools.TabIndex = 0;
|
||||||
groupBoxTools.TabStop = false;
|
groupBoxTools.TabStop = false;
|
||||||
groupBoxTools.Text = "Инструменты";
|
groupBoxTools.Text = "Инструменты";
|
||||||
@ -84,20 +84,20 @@
|
|||||||
// buttonAddFighter
|
// buttonAddFighter
|
||||||
//
|
//
|
||||||
buttonAddFighter.Anchor = AnchorStyles.Top | AnchorStyles.Left | AnchorStyles.Right;
|
buttonAddFighter.Anchor = AnchorStyles.Top | AnchorStyles.Left | AnchorStyles.Right;
|
||||||
buttonAddFighter.Location = new Point(6, 0);
|
buttonAddFighter.Location = new Point(6, 59);
|
||||||
buttonAddFighter.Name = "buttonAddFighter";
|
buttonAddFighter.Name = "buttonAddFighter";
|
||||||
buttonAddFighter.Size = new Size(273, 52);
|
buttonAddFighter.Size = new Size(273, 59);
|
||||||
buttonAddFighter.TabIndex = 2;
|
buttonAddFighter.TabIndex = 2;
|
||||||
buttonAddFighter.Text = "Добавление истребителя";
|
buttonAddFighter.Text = "Добавление гусеничной машины с оборудованием";
|
||||||
buttonAddFighter.UseVisualStyleBackColor = true;
|
buttonAddFighter.UseVisualStyleBackColor = true;
|
||||||
buttonAddFighter.Click += ButtonAddTrackedVehicle_Click;
|
buttonAddFighter.Click += ButtonAddFighter_Click;
|
||||||
//
|
//
|
||||||
// buttonAddTrackedVehicle
|
// buttonAddTrackedVehicle
|
||||||
//
|
//
|
||||||
buttonAddTrackedVehicle.Anchor = AnchorStyles.Top | AnchorStyles.Left | AnchorStyles.Right;
|
buttonAddTrackedVehicle.Anchor = AnchorStyles.Top | AnchorStyles.Left | AnchorStyles.Right;
|
||||||
buttonAddTrackedVehicle.Location = new Point(6, 58);
|
buttonAddTrackedVehicle.Location = new Point(6, 0);
|
||||||
buttonAddTrackedVehicle.Name = "buttonAddTrackedVehicle";
|
buttonAddTrackedVehicle.Name = "buttonAddTrackedVehicle";
|
||||||
buttonAddTrackedVehicle.Size = new Size(273, 60);
|
buttonAddTrackedVehicle.Size = new Size(273, 63);
|
||||||
buttonAddTrackedVehicle.TabIndex = 3;
|
buttonAddTrackedVehicle.TabIndex = 3;
|
||||||
buttonAddTrackedVehicle.Text = "Добавление гусеничной машины";
|
buttonAddTrackedVehicle.Text = "Добавление гусеничной машины";
|
||||||
buttonAddTrackedVehicle.UseVisualStyleBackColor = true;
|
buttonAddTrackedVehicle.UseVisualStyleBackColor = true;
|
||||||
@ -256,7 +256,7 @@
|
|||||||
pictureBox.Dock = DockStyle.Fill;
|
pictureBox.Dock = DockStyle.Fill;
|
||||||
pictureBox.Location = new Point(0, 0);
|
pictureBox.Location = new Point(0, 0);
|
||||||
pictureBox.Name = "pictureBox";
|
pictureBox.Name = "pictureBox";
|
||||||
pictureBox.Size = new Size(670, 617);
|
pictureBox.Size = new Size(635, 615);
|
||||||
pictureBox.TabIndex = 1;
|
pictureBox.TabIndex = 1;
|
||||||
pictureBox.TabStop = false;
|
pictureBox.TabStop = false;
|
||||||
pictureBox.Click += pictureBox1_Click;
|
pictureBox.Click += pictureBox1_Click;
|
||||||
@ -265,7 +265,7 @@
|
|||||||
//
|
//
|
||||||
AutoScaleDimensions = new SizeF(10F, 25F);
|
AutoScaleDimensions = new SizeF(10F, 25F);
|
||||||
AutoScaleMode = AutoScaleMode.Font;
|
AutoScaleMode = AutoScaleMode.Font;
|
||||||
ClientSize = new Size(967, 617);
|
ClientSize = new Size(932, 615);
|
||||||
Controls.Add(pictureBox);
|
Controls.Add(pictureBox);
|
||||||
Controls.Add(groupBoxTools);
|
Controls.Add(groupBoxTools);
|
||||||
Name = "FormTrackedVehicleCollection";
|
Name = "FormTrackedVehicleCollection";
|
||||||
|
@ -47,7 +47,7 @@ public partial class FormTrackedVehicleCollection : Form
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="sender"></param>
|
/// <param name="sender"></param>
|
||||||
/// <param name="e"></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>
|
/// <summary>
|
||||||
/// Создание объекта класса-перемещения
|
/// Создание объекта класса-перемещения
|
||||||
|
Loading…
Reference in New Issue
Block a user