diff --git a/Tank/Tank/Direction.cs b/Tank/Tank/Direction.cs new file mode 100644 index 0000000..96e9c9f --- /dev/null +++ b/Tank/Tank/Direction.cs @@ -0,0 +1,32 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Tank +{ + /// + /// Направление перемещения + /// + public enum Direction + { + /// + /// Вверх + /// + /// + Up = 1, + /// + /// Вниз + /// + Down = 2, + /// + /// Влево + /// + Left = 3, + /// + /// Вправо + /// + Right = 4 + } +} diff --git a/Tank/Tank/DrawingTank.cs b/Tank/Tank/DrawingTank.cs new file mode 100644 index 0000000..8aa0a4c --- /dev/null +++ b/Tank/Tank/DrawingTank.cs @@ -0,0 +1,251 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Tank +{ + /// + /// Класс, отвечающий за прорисовку и перемещение объекта-сущности + /// + public class DrawningTank + { + /// + /// Класс-сущность + /// + public EntityTank? EntityTank { get; private set; } + /// + /// Ширина окна + /// + private int _pictureWidth = 900; + /// + /// Высота окна + /// + private int _pictureHeight = 500; + /// + /// Левая координата прорисовки автомобиля + /// + private int _startPosX; + /// + /// Верхняя кооридната прорисовки автомобиля + /// + private int _startPosY; + /// + /// Ширина прорисовки автомобиля + /// + private readonly int _tankWidth = 110; + /// + /// Высота прорисовки автомобиля + /// + private readonly int _tankHeight = 60; + /// + /// Инициализация свойств + /// + /// Скорость + /// Вес + /// Цвет кузова + /// Дополнительный цвет + /// Признак наличия обвеса + /// Признак наличия антикрыла + /// Признак наличия гоночной полосы + /// Ширина картинки + /// Высота картинки + /// true - объект создан, false - проверка не пройдена, + /// нельзя создать объект в этих размерах + public bool Init(int speed, double weight, Color bodyColor, Color + additionalColor, bool bodyKit, bool wing, bool sportLine, int width, int height) + { + // TODO: Продумать проверки + _pictureWidth = width; + _pictureHeight = height; + EntityTank = new EntityTank(); + EntityTank.Init(speed, weight, bodyColor, additionalColor, + bodyKit, wing, sportLine); + return true; + } + /// + /// Установка позиции + /// + /// Координата X + /// Координата Y + public void SetPosition(int x, int y) + { + // TODO: Изменение x, y + _startPosX = x; + _startPosY = y; + } + /// + /// Изменение направления перемещения + /// + /// Направление + public void MoveTransport(Direction direction) + { + if (EntityTank == null) + { + return; + } + switch (direction) + { + //влево + case Direction.Left: + if (_startPosX - EntityTank.Step > 0) + { + _startPosX -= (int)EntityTank.Step; + } + break; + //вверх + case Direction.Up: + if (_startPosY - EntityTank.Step > 0) + { + _startPosY -= (int)EntityTank.Step; + } + break; + // вправо + case Direction.Right: + // TODO: Продумать логику + if (_startPosX + EntityTank.Step + _tankWidth < _pictureWidth) + { + _startPosX += (int)EntityTank.Step; + } + break; + //вниз + case Direction.Down: + // TODO: Продумать логику + if (_startPosY + EntityTank.Step + _tankHeight < _pictureHeight) + { + _startPosY += (int)EntityTank.Step; + } + break; + } + } + /// + /// Прорисовка объекта + /// + /// + public void DrawTransport(Graphics g) + { + if (EntityTank == null) + { + return; + } + Pen pen = new(Color.Black); + Brush additionalBrush = new + SolidBrush(EntityTank.AdditionalColor); +// // обвесы +// if (EntityTank.BodyKit) +// { +// g.DrawEllipse(pen, _startPosX + 90, _startPosY, 20, 20); +// g.DrawEllipse(pen, _startPosX + 90, _startPosY + 40, 20, +// 20); +// g.DrawRectangle(pen, _startPosX + 90, _startPosY + 10, +// 20, 40); +// g.DrawRectangle(pen, _startPosX + 90, _startPosY, 15, +// 15); +// g.DrawRectangle(pen, _startPosX + 90, _startPosY + 45, +// 15, 15); +// g.FillEllipse(additionalBrush, _startPosX + 90, +// _startPosY, 20, 20); +// g.FillEllipse(additionalBrush, _startPosX + 90, +// _startPosY + 40, 20, 20); +// g.FillRectangle(additionalBrush, _startPosX + 90, +// _startPosY + 10, 20, 40); + +// g.FillRectangle(additionalBrush, _startPosX + 90, +//_startPosY + 1, 15, 15); +// g.FillRectangle(additionalBrush, _startPosX + 90, +// _startPosY + 45, 15, 15); +// g.DrawEllipse(pen, _startPosX, _startPosY, 20, 20); +// g.DrawEllipse(pen, _startPosX, _startPosY + 40, 20, 20); +// g.DrawRectangle(pen, _startPosX, _startPosY + 10, 20, +// 40); +// g.DrawRectangle(pen, _startPosX + 5, _startPosY, 14, +// 15); +// g.DrawRectangle(pen, _startPosX + 5, _startPosY + 45, +// 14, 15); +// g.FillEllipse(additionalBrush, _startPosX, _startPosY, +// 20, 20); +// g.FillEllipse(additionalBrush, _startPosX, _startPosY + +// 40, 20, 20); +// g.FillRectangle(additionalBrush, _startPosX + 1, +// _startPosY + 10, 25, 40); +// g.FillRectangle(additionalBrush, _startPosX + 5, +// _startPosY + 1, 15, 15); +// g.FillRectangle(additionalBrush, _startPosX + 5, +// _startPosY + 45, 15, 15); +// g.DrawRectangle(pen, _startPosX + 35, _startPosY, 39, +//15); +// g.DrawRectangle(pen, _startPosX + 35, _startPosY + 45, +// 39, 15); +// g.FillRectangle(additionalBrush, _startPosX + 35, +// _startPosY + 1, 40, 15); +// g.FillRectangle(additionalBrush, _startPosX + 35, +// _startPosY + 45, 40, 15); +// } + ////границы автомобиля + //g.DrawEllipse(pen, _startPosX + 10, _startPosY + 5, 20, 20); + //g.DrawEllipse(pen, _startPosX + 10, _startPosY + 35, 20, 20); + //g.DrawEllipse(pen, _startPosX + 80, _startPosY + 5, 20, 20); + //g.DrawEllipse(pen, _startPosX + 80, _startPosY + 35, 20, 20); + //g.DrawRectangle(pen, _startPosX + 9, _startPosY + 15, 10, 30); + //g.DrawRectangle(pen, _startPosX + 90, _startPosY + 15, 10, + //30); + //g.DrawRectangle(pen, _startPosX + 20, _startPosY + 4, 70, 52); + //////задние фары + //Brush brRed = new SolidBrush(Color.Red); + //g.FillEllipse(brRed, _startPosX + 10, _startPosY + 5, 20, 20); + //g.FillEllipse(brRed, _startPosX + 10, _startPosY + 35, 20, + //20); + ////передние фары + //Brush brYellow = new SolidBrush(Color.Yellow); + //g.FillEllipse(brYellow, _startPosX + 80, _startPosY + 5, 20, + //20); + //g.FillEllipse(brYellow, _startPosX + 80, _startPosY + 35, 20, + //20); + + //кузов + Brush br = new SolidBrush(EntityTank.BodyColor); + g.FillRectangle(br, _startPosX + 5, _startPosY + 15, 65, 15); + g.FillRectangle(br, _startPosX + 20, _startPosY, 30, 20); + // пулемет + g.FillRectangle(br, _startPosX + 50, _startPosY + 3, 15, 5); + + + ////стекла + //Brush brBlue = new SolidBrush(Color.LightBlue); + //g.FillRectangle(brBlue, _startPosX + 70, _startPosY + 10, 5, + //40); + //g.FillRectangle(brBlue, _startPosX + 30, _startPosY + 10, 5, + //40); + //g.FillRectangle(brBlue, _startPosX + 35, _startPosY + 8, 35, + //2); + //g.FillRectangle(brBlue, _startPosX + 35, _startPosY + 51, 35, + //2); + ////выделяем рамкой крышу + //g.DrawRectangle(pen, _startPosX + 35, _startPosY + 10, 35, + //40); + //g.DrawRectangle(pen, _startPosX + 75, _startPosY + 15, 25, + //30); + //g.DrawRectangle(pen, _startPosX + 10, _startPosY + 15, 15, + //30); + //// спортивная линия + //if (EntityTank.SportLine) + //{ + // g.FillRectangle(additionalBrush, _startPosX + 75, + // _startPosY + 23, 25, 15); + // g.FillRectangle(additionalBrush, _startPosX + 35, + // _startPosY + 23, 35, 15); + // g.FillRectangle(additionalBrush, _startPosX + 10, + // _startPosY + 23, 20, 15); + //} + // крыло + //if (EntityTank.Wing) + //{ + // g.FillRectangle(additionalBrush, _startPosX, _startPosY + // + 5, 10, 50); + // g.DrawRectangle(pen, _startPosX, _startPosY + 5, 10, + // 50); + //} + } + } +} \ No newline at end of file diff --git a/Tank/Tank/EntityTank.cs b/Tank/Tank/EntityTank.cs new file mode 100644 index 0000000..507f0a7 --- /dev/null +++ b/Tank/Tank/EntityTank.cs @@ -0,0 +1,66 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Tank +{ + public class EntityTank + { + /// + /// Скорость + /// + public int Speed { get; private set; } + /// + /// Вес + /// + public double Weight { get; private set; } + /// + /// Основной цвет + /// + public Color BodyColor { get; private set; } + /// + /// Дополнительный цвет (для опциональных элементов) + /// + public Color AdditionalColor { get; private set; } + /// + /// Признак (опция) наличия обвеса + /// + public bool BodyKit { get; private set; } + /// + /// Признак (опция) наличия антикрыла + /// + public bool Wing { get; private set; } + /// + /// Признак (опция) наличия гоночной полосы + /// + public bool SportLine { get; private set; } + /// + /// Шаг перемещения автомобиля + /// + public double Step => (double)Speed * 100 / Weight; + /// + /// Инициализация полей объекта-класса спортивного автомобиля + /// + /// Скорость + /// Вес автомобиля + /// Основной цвет + /// Дополнительный цвет + /// Признак наличия обвеса + /// Признак наличия антикрыла + /// Признак наличия гоночной полосы + public void Init(int speed, double weight, Color bodyColor, Color + additionalColor, bool bodyKit, bool wing, bool sportLine) + { + Speed = speed; + Weight = weight; + BodyColor = bodyColor; + AdditionalColor = additionalColor; + BodyKit = bodyKit; + Wing = wing; + SportLine = sportLine; + } + } +} + diff --git a/Tank/Tank/Form1.Designer.cs b/Tank/Tank/Form1.Designer.cs deleted file mode 100644 index 237f42c..0000000 --- a/Tank/Tank/Form1.Designer.cs +++ /dev/null @@ -1,39 +0,0 @@ -namespace Tank -{ - partial class Form1 - { - /// - /// Required designer variable. - /// - private System.ComponentModel.IContainer components = null; - - /// - /// Clean up any resources being used. - /// - /// true if managed resources should be disposed; otherwise, false. - protected override void Dispose(bool disposing) - { - if (disposing && (components != null)) - { - components.Dispose(); - } - base.Dispose(disposing); - } - - #region Windows Form Designer generated code - - /// - /// Required method for Designer support - do not modify - /// the contents of this method with the code editor. - /// - private void InitializeComponent() - { - this.components = new System.ComponentModel.Container(); - this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.ClientSize = new System.Drawing.Size(800, 450); - this.Text = "Form1"; - } - - #endregion - } -} \ No newline at end of file diff --git a/Tank/Tank/Form1.cs b/Tank/Tank/Form1.cs deleted file mode 100644 index db4ac92..0000000 --- a/Tank/Tank/Form1.cs +++ /dev/null @@ -1,10 +0,0 @@ -namespace Tank -{ - public partial class Form1 : Form - { - public Form1() - { - InitializeComponent(); - } - } -} \ No newline at end of file diff --git a/Tank/Tank/FormTank.Designer.cs b/Tank/Tank/FormTank.Designer.cs new file mode 100644 index 0000000..a8edc13 --- /dev/null +++ b/Tank/Tank/FormTank.Designer.cs @@ -0,0 +1,131 @@ +namespace Tank +{ + partial class FormTank + { + /// + /// Required designer variable. + /// + private System.ComponentModel.IContainer components = null; + + /// + /// Clean up any resources being used. + /// + /// true if managed resources should be disposed; otherwise, false. + protected override void Dispose(bool disposing) + { + if (disposing && (components != null)) + { + components.Dispose(); + } + base.Dispose(disposing); + } + + #region Windows Form Designer generated code + + /// + /// Required method for Designer support - do not modify + /// the contents of this method with the code editor. + /// + private void InitializeComponent() + { + this.pictureBoxTank = new System.Windows.Forms.PictureBox(); + this.buttonCreate = new System.Windows.Forms.Button(); + this.buttonUp = new System.Windows.Forms.Button(); + this.buttonLeft = new System.Windows.Forms.Button(); + this.buttonDown = new System.Windows.Forms.Button(); + this.buttonRight = new System.Windows.Forms.Button(); + ((System.ComponentModel.ISupportInitialize)(this.pictureBoxTank)).BeginInit(); + this.SuspendLayout(); + // + // pictureBoxTank + // + this.pictureBoxTank.Dock = System.Windows.Forms.DockStyle.Fill; + this.pictureBoxTank.Location = new System.Drawing.Point(0, 0); + this.pictureBoxTank.Name = "pictureBoxTank"; + this.pictureBoxTank.Size = new System.Drawing.Size(884, 461); + this.pictureBoxTank.SizeMode = System.Windows.Forms.PictureBoxSizeMode.AutoSize; + this.pictureBoxTank.TabIndex = 0; + this.pictureBoxTank.TabStop = false; + this.pictureBoxTank.Click += new System.EventHandler(this.pictureBox1_Click); + // + // buttonCreate + // + this.buttonCreate.Location = new System.Drawing.Point(42, 417); + this.buttonCreate.Name = "buttonCreate"; + this.buttonCreate.Size = new System.Drawing.Size(75, 23); + this.buttonCreate.TabIndex = 1; + this.buttonCreate.Text = "Создать"; + this.buttonCreate.UseVisualStyleBackColor = true; + this.buttonCreate.Click += new System.EventHandler(this.buttonCreate_Click); + // + // buttonUp + // + this.buttonUp.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.buttonUp.Location = new System.Drawing.Point(806, 381); + this.buttonUp.Name = "buttonUp"; + this.buttonUp.Size = new System.Drawing.Size(30, 30); + this.buttonUp.TabIndex = 2; + this.buttonUp.UseVisualStyleBackColor = true; + this.buttonUp.Click += new System.EventHandler(this.buttonMove_Click); + // + // buttonLeft + // + this.buttonLeft.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.buttonLeft.Location = new System.Drawing.Point(770, 419); + this.buttonLeft.Name = "buttonLeft"; + this.buttonLeft.Size = new System.Drawing.Size(30, 30); + this.buttonLeft.TabIndex = 3; + this.buttonLeft.UseVisualStyleBackColor = true; + this.buttonLeft.Click += new System.EventHandler(this.buttonMove_Click); + // + // buttonDown + // + this.buttonDown.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.buttonDown.Location = new System.Drawing.Point(806, 417); + this.buttonDown.Name = "buttonDown"; + this.buttonDown.Size = new System.Drawing.Size(30, 30); + this.buttonDown.TabIndex = 4; + this.buttonDown.UseVisualStyleBackColor = true; + this.buttonDown.Click += new System.EventHandler(this.buttonMove_Click); + // + // buttonRight + // + this.buttonRight.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.buttonRight.Location = new System.Drawing.Point(842, 417); + this.buttonRight.Name = "buttonRight"; + this.buttonRight.Size = new System.Drawing.Size(30, 30); + this.buttonRight.TabIndex = 5; + this.buttonRight.UseVisualStyleBackColor = true; + this.buttonRight.Click += new System.EventHandler(this.buttonMove_Click); + // + // FormTank + // + this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.ClientSize = new System.Drawing.Size(884, 461); + this.Controls.Add(this.buttonRight); + this.Controls.Add(this.buttonDown); + this.Controls.Add(this.buttonLeft); + this.Controls.Add(this.buttonUp); + this.Controls.Add(this.buttonCreate); + this.Controls.Add(this.pictureBoxTank); + this.Name = "FormTank"; + this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen; + this.Text = "Tank"; + this.Load += new System.EventHandler(this.Form1_Load); + ((System.ComponentModel.ISupportInitialize)(this.pictureBoxTank)).EndInit(); + this.ResumeLayout(false); + this.PerformLayout(); + + } + + #endregion + + private PictureBox pictureBoxTank; + private Button buttonCreate; + private Button buttonUp; + private Button buttonLeft; + private Button buttonDown; + private Button buttonRight; + } +} \ No newline at end of file diff --git a/Tank/Tank/FormTank.cs b/Tank/Tank/FormTank.cs new file mode 100644 index 0000000..c0179b1 --- /dev/null +++ b/Tank/Tank/FormTank.cs @@ -0,0 +1,99 @@ +namespace Tank +{ + /// + /// " " + /// + public partial class FormTank : Form + { + /// + /// - + /// + private DrawningTank? _drawningTank; + /// + /// + /// + public FormTank() + { + InitializeComponent(); + } + /// + /// + /// + private void Draw() + { + if (_drawningTank == null) + { + return; + } + Bitmap bmp = new(pictureBoxTank.Width, + pictureBoxTank.Height); + Graphics gr = Graphics.FromImage(bmp); + _drawningTank.DrawTransport(gr); + pictureBoxTank.Image = bmp; + } + /// + /// "" + /// + /// + /// + private void Form1_Load(object sender, EventArgs e) + { + + + } + + private void pictureBox1_Click(object sender, EventArgs e) + { + + } + + private void buttonCreate_Click(object sender, EventArgs e) + { + Random random = new(); + _drawningTank = new DrawningTank(); + _drawningTank.Init(random.Next(100, 300), + random.Next(1000, 3000), + Color.FromArgb(random.Next(0, 256), random.Next(0, 256), + random.Next(0, 256)), + Color.FromArgb(random.Next(0, 256), random.Next(0, 256), + random.Next(0, 256)), + Convert.ToBoolean(random.Next(0, 2)), + Convert.ToBoolean(random.Next(0, 2)), Convert.ToBoolean(random.Next(0, 2)), + + pictureBoxTank.Width, pictureBoxTank.Height); + _drawningTank.SetPosition(random.Next(10, 100), + random.Next(10, 100)); + Draw(); + } + /// + /// + /// + /// + /// + private void buttonMove_Click(object sender, EventArgs e) + { + if (_drawningTank == null) + { + return; + } + string name = ((Button)sender)?.Name ?? string.Empty; + switch (name) + { + case "buttonUp": + _drawningTank.MoveTransport(Direction.Up); + break; + case "buttonDown": + _drawningTank.MoveTransport(Direction.Down); + break; + case "buttonLeft": + _drawningTank.MoveTransport(Direction.Left); + break; + case "buttonRight": + _drawningTank.MoveTransport(Direction.Right); + break; + } + Draw(); + + } + } +} \ No newline at end of file diff --git a/Tank/Tank/FormTank.resx b/Tank/Tank/FormTank.resx new file mode 100644 index 0000000..f298a7b --- /dev/null +++ b/Tank/Tank/FormTank.resx @@ -0,0 +1,60 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + \ No newline at end of file diff --git a/Tank/Tank/Program.cs b/Tank/Tank/Program.cs index 1b63cfc..3fbc0e1 100644 --- a/Tank/Tank/Program.cs +++ b/Tank/Tank/Program.cs @@ -11,7 +11,7 @@ namespace Tank // To customize application configuration such as set high DPI settings or default font, // see https://aka.ms/applicationconfiguration. ApplicationConfiguration.Initialize(); - Application.Run(new Form1()); + Application.Run(new FormTank()); } } } \ No newline at end of file diff --git a/Tank/Tank/Properties/Resources.Designer.cs b/Tank/Tank/Properties/Resources.Designer.cs new file mode 100644 index 0000000..8f7daa5 --- /dev/null +++ b/Tank/Tank/Properties/Resources.Designer.cs @@ -0,0 +1,103 @@ +//------------------------------------------------------------------------------ +// +// Этот код создан программой. +// Исполняемая версия:4.0.30319.42000 +// +// Изменения в этом файле могут привести к неправильной работе и будут потеряны в случае +// повторной генерации кода. +// +//------------------------------------------------------------------------------ + +namespace Tank.Properties { + using System; + + + /// + /// Класс ресурса со строгой типизацией для поиска локализованных строк и т.д. + /// + // Этот класс создан автоматически классом StronglyTypedResourceBuilder + // с помощью такого средства, как ResGen или Visual Studio. + // Чтобы добавить или удалить член, измените файл .ResX и снова запустите ResGen + // с параметром /str или перестройте свой проект VS. + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "17.0.0.0")] + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] + internal class Resources { + + private static global::System.Resources.ResourceManager resourceMan; + + private static global::System.Globalization.CultureInfo resourceCulture; + + [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] + internal Resources() { + } + + /// + /// Возвращает кэшированный экземпляр ResourceManager, использованный этим классом. + /// + [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] + internal static global::System.Resources.ResourceManager ResourceManager { + get { + if (object.ReferenceEquals(resourceMan, null)) { + global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("Tank.Properties.Resources", typeof(Resources).Assembly); + resourceMan = temp; + } + return resourceMan; + } + } + + /// + /// Перезаписывает свойство CurrentUICulture текущего потока для всех + /// обращений к ресурсу с помощью этого класса ресурса со строгой типизацией. + /// + [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] + internal static global::System.Globalization.CultureInfo Culture { + get { + return resourceCulture; + } + set { + resourceCulture = value; + } + } + + /// + /// Поиск локализованного ресурса типа System.Drawing.Bitmap. + /// + internal static System.Drawing.Bitmap down_arrow { + get { + object obj = ResourceManager.GetObject("down-arrow", resourceCulture); + return ((System.Drawing.Bitmap)(obj)); + } + } + + /// + /// Поиск локализованного ресурса типа System.Drawing.Bitmap. + /// + internal static System.Drawing.Bitmap left_arrow { + get { + object obj = ResourceManager.GetObject("left-arrow", resourceCulture); + return ((System.Drawing.Bitmap)(obj)); + } + } + + /// + /// Поиск локализованного ресурса типа System.Drawing.Bitmap. + /// + internal static System.Drawing.Bitmap right_arrow { + get { + object obj = ResourceManager.GetObject("right-arrow", resourceCulture); + return ((System.Drawing.Bitmap)(obj)); + } + } + + /// + /// Поиск локализованного ресурса типа System.Drawing.Bitmap. + /// + internal static System.Drawing.Bitmap upper_arrow { + get { + object obj = ResourceManager.GetObject("upper-arrow", resourceCulture); + return ((System.Drawing.Bitmap)(obj)); + } + } + } +} diff --git a/Tank/Tank/Form1.resx b/Tank/Tank/Properties/Resources.resx similarity index 83% rename from Tank/Tank/Form1.resx rename to Tank/Tank/Properties/Resources.resx index 1af7de1..f4f3416 100644 --- a/Tank/Tank/Form1.resx +++ b/Tank/Tank/Properties/Resources.resx @@ -117,4 +117,17 @@ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + ..\Resources\down-arrow.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\Resources\left-arrow.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\Resources\right-arrow.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\Resources\upper-arrow.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + \ No newline at end of file diff --git a/Tank/Tank/Resources/down-arrow.png b/Tank/Tank/Resources/down-arrow.png new file mode 100644 index 0000000..9d67143 Binary files /dev/null and b/Tank/Tank/Resources/down-arrow.png differ diff --git a/Tank/Tank/Resources/left-arrow.png b/Tank/Tank/Resources/left-arrow.png new file mode 100644 index 0000000..046470d Binary files /dev/null and b/Tank/Tank/Resources/left-arrow.png differ diff --git a/Tank/Tank/Resources/right-arrow.png b/Tank/Tank/Resources/right-arrow.png new file mode 100644 index 0000000..fac4c96 Binary files /dev/null and b/Tank/Tank/Resources/right-arrow.png differ diff --git a/Tank/Tank/Resources/upper-arrow.png b/Tank/Tank/Resources/upper-arrow.png new file mode 100644 index 0000000..0bc323d Binary files /dev/null and b/Tank/Tank/Resources/upper-arrow.png differ diff --git a/Tank/Tank/Tank.csproj b/Tank/Tank/Tank.csproj index b57c89e..13ee123 100644 --- a/Tank/Tank/Tank.csproj +++ b/Tank/Tank/Tank.csproj @@ -8,4 +8,19 @@ enable + + + True + True + Resources.resx + + + + + + ResXFileCodeGenerator + Resources.Designer.cs + + + \ No newline at end of file