From 3b2f788d4fbe6d0361edd698332ce938b71a8bd6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=9C=D0=B0=D0=BA=D1=81=D0=B8=D0=BC=20=D0=95=D0=B3=D0=BE?= =?UTF-8?q?=D1=80=D0=BE=D0=B2?= Date: Sun, 6 Oct 2024 20:46:58 +0400 Subject: [PATCH] =?UTF-8?q?=D0=A2=D1=80=D0=B5=D1=82=D0=B8=D0=B9=20=D1=8D?= =?UTF-8?q?=D1=82=D0=B0=D0=BF=20Lab8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Sailboat/Sailboat/EntityBoat.cs | 4 - Sailboat/Sailboat/EntitySailboat.cs | 4 - .../Sailboat/FormBoatCollection.Designer.cs | 32 ++++---- Sailboat/Sailboat/FormBoatCollection.resx | 74 ++++--------------- Sailboat/Sailboat/FormSailboat.Designer.cs | 68 +++++------------ 5 files changed, 46 insertions(+), 136 deletions(-) diff --git a/Sailboat/Sailboat/EntityBoat.cs b/Sailboat/Sailboat/EntityBoat.cs index 85cdb6d..21f56b2 100644 --- a/Sailboat/Sailboat/EntityBoat.cs +++ b/Sailboat/Sailboat/EntityBoat.cs @@ -13,10 +13,6 @@ namespace Sailboat.Entities public Color BodyColor { get; private set; } public void setBodyColor(Color color) { BodyColor = color; } public double Step => (double)Speed * 100 / Weight; - public void ChangeColor(Color color) - { - BodyColor = color; - } /// /// Конструктор с параметрами diff --git a/Sailboat/Sailboat/EntitySailboat.cs b/Sailboat/Sailboat/EntitySailboat.cs index e1f3f25..844d138 100644 --- a/Sailboat/Sailboat/EntitySailboat.cs +++ b/Sailboat/Sailboat/EntitySailboat.cs @@ -12,10 +12,6 @@ namespace Sailboat.Entities public void setAdditionalColor(Color color) { AdditionalColor = color; } public bool Hull { get; private set; } public bool Sail { get; private set; } - public void ChangeAddColor(Color color) - { - AdditionalColor = color; - } /// /// Инициализация полей объекта-класса парусной лодки diff --git a/Sailboat/Sailboat/FormBoatCollection.Designer.cs b/Sailboat/Sailboat/FormBoatCollection.Designer.cs index dc339b9..07c1e08 100644 --- a/Sailboat/Sailboat/FormBoatCollection.Designer.cs +++ b/Sailboat/Sailboat/FormBoatCollection.Designer.cs @@ -183,7 +183,6 @@ namespace Sailboat menuStrip.Padding = new Padding(5, 2, 0, 2); menuStrip.Size = new Size(183, 24); menuStrip.TabIndex = 5; - this.menuStrip.TabIndex = 5; // // toolStripMenuItem1 // @@ -196,8 +195,7 @@ namespace Sailboat ToolStripMenuItem.Name = "ToolStripMenuItem"; ToolStripMenuItem.Size = new Size(48, 20); ToolStripMenuItem.Text = "Файл"; - this.ToolStripMenuItem.Size = new System.Drawing.Size(59, 24); - this.ToolStripMenuItem.Text = "Файл"; + ToolStripMenuItem.Size = new System.Drawing.Size(59, 24); // // SaveToolStripMenuItem // @@ -224,23 +222,23 @@ namespace Sailboat // // buttonSortByType // - this.buttonSortByType.Location = new System.Drawing.Point(20, 448); - this.buttonSortByType.Name = "buttonSortByType"; - this.buttonSortByType.Size = new System.Drawing.Size(180, 34); - this.buttonSortByType.TabIndex = 6; - this.buttonSortByType.Text = "Сортировать по типу"; - this.buttonSortByType.UseVisualStyleBackColor = true; - this.buttonSortByType.Click += new System.EventHandler(this.buttonSortByType_Click); + buttonSortByType.Location = new System.Drawing.Point(20, 348); + buttonSortByType.Name = "buttonSortByType"; + buttonSortByType.Size = new System.Drawing.Size(180, 34); + buttonSortByType.TabIndex = 6; + buttonSortByType.Text = "Сортировать по типу"; + buttonSortByType.UseVisualStyleBackColor = true; + buttonSortByType.Click += new System.EventHandler(this.buttonSortByType_Click); // // buttonSortByColor // - this.buttonSortByColor.Location = new System.Drawing.Point(20, 488); - this.buttonSortByColor.Name = "buttonSortByColor"; - this.buttonSortByColor.Size = new System.Drawing.Size(180, 34); - this.buttonSortByColor.TabIndex = 7; - this.buttonSortByColor.Text = "Сортировать по цвету"; - this.buttonSortByColor.UseVisualStyleBackColor = true; - this.buttonSortByColor.Click += new System.EventHandler(this.buttonSortByColor_Click); + buttonSortByColor.Location = new System.Drawing.Point(20, 488); + buttonSortByColor.Name = "buttonSortByColor"; + buttonSortByColor.Size = new System.Drawing.Size(180, 34); + buttonSortByColor.TabIndex = 7; + buttonSortByColor.Text = "Сортировать по цвету"; + buttonSortByColor.UseVisualStyleBackColor = true; + buttonSortByColor.Click += new System.EventHandler(this.buttonSortByColor_Click); // // FormBoatCollection // diff --git a/Sailboat/Sailboat/FormBoatCollection.resx b/Sailboat/Sailboat/FormBoatCollection.resx index af32865..3198a4b 100644 --- a/Sailboat/Sailboat/FormBoatCollection.resx +++ b/Sailboat/Sailboat/FormBoatCollection.resx @@ -1,64 +1,4 @@ - - - + @@ -117,4 +57,16 @@ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 17, 17 + + + 144, 0 + + + 144, 0 + + + 25 + \ No newline at end of file diff --git a/Sailboat/Sailboat/FormSailboat.Designer.cs b/Sailboat/Sailboat/FormSailboat.Designer.cs index a8eefa0..d5f33da 100644 --- a/Sailboat/Sailboat/FormSailboat.Designer.cs +++ b/Sailboat/Sailboat/FormSailboat.Designer.cs @@ -29,28 +29,17 @@ private void InitializeComponent() { System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(FormSailboat)); - this.pictureBoxSailboat = new System.Windows.Forms.PictureBox(); - this.buttonCreateBoat = new System.Windows.Forms.Button(); - this.buttonLeft = new System.Windows.Forms.Button(); - this.buttonUp = new System.Windows.Forms.Button(); - this.buttonRight = new System.Windows.Forms.Button(); - this.buttonDown = new System.Windows.Forms.Button(); - this.buttonCreateSailboat = new System.Windows.Forms.Button(); - this.comboBoxStrategy = new System.Windows.Forms.ComboBox(); - this.buttonStep = new System.Windows.Forms.Button(); - this.buttonSelectBoat = new System.Windows.Forms.Button(); - ((System.ComponentModel.ISupportInitialize)(this.pictureBoxSailboat)).BeginInit(); - this.SuspendLayout(); - pictureBoxSailboat = new PictureBox(); - buttonCreateBoat = new Button(); - buttonLeft = new Button(); - buttonUp = new Button(); - buttonRight = new Button(); - buttonDown = new Button(); - buttonCreateSailboat = new Button(); - comboBoxStrategy = new ComboBox(); - buttonStep = new Button(); - ((System.ComponentModel.ISupportInitialize)pictureBoxSailboat).BeginInit(); + pictureBoxSailboat = new System.Windows.Forms.PictureBox(); + buttonCreateBoat = new System.Windows.Forms.Button(); + buttonLeft = new System.Windows.Forms.Button(); + buttonUp = new System.Windows.Forms.Button(); + buttonRight = new System.Windows.Forms.Button(); + buttonDown = new System.Windows.Forms.Button(); + buttonCreateSailboat = new System.Windows.Forms.Button(); + comboBoxStrategy = new System.Windows.Forms.ComboBox(); + buttonStep = new System.Windows.Forms.Button(); + buttonSelectBoat = new System.Windows.Forms.Button(); + ((System.ComponentModel.ISupportInitialize)(pictureBoxSailboat)).BeginInit(); SuspendLayout(); // // pictureBoxSailboat @@ -166,37 +155,16 @@ // // buttonSelectBoat // - this.buttonSelectBoat.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); - this.buttonSelectBoat.Location = new System.Drawing.Point(688, 97); - this.buttonSelectBoat.Name = "buttonSelectBoat"; - this.buttonSelectBoat.Size = new System.Drawing.Size(149, 33); - this.buttonSelectBoat.TabIndex = 9; - this.buttonSelectBoat.Text = "Выбрать лодку"; - this.buttonSelectBoat.UseVisualStyleBackColor = true; - this.buttonSelectBoat.Click += new System.EventHandler(this.buttonSelectBoat_Click); + buttonSelectBoat.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); + buttonSelectBoat.Location = new System.Drawing.Point(688, 97); + buttonSelectBoat.Name = "buttonSelectBoat"; + buttonSelectBoat.Size = new System.Drawing.Size(149, 33); + buttonSelectBoat.TabIndex = 9; + buttonSelectBoat.Text = "Выбрать лодку"; + buttonSelectBoat.UseVisualStyleBackColor = true; // // FormSailboat // - this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 20F); - this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.ClientSize = new System.Drawing.Size(882, 453); - this.Controls.Add(this.buttonSelectBoat); - this.Controls.Add(this.buttonStep); - this.Controls.Add(this.comboBoxStrategy); - this.Controls.Add(this.buttonCreateSailboat); - this.Controls.Add(this.buttonDown); - this.Controls.Add(this.buttonRight); - this.Controls.Add(this.buttonUp); - this.Controls.Add(this.buttonLeft); - this.Controls.Add(this.buttonCreateBoat); - this.Controls.Add(this.pictureBoxSailboat); - this.Name = "FormSailboat"; - this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen; - this.Text = "Парусник"; - ((System.ComponentModel.ISupportInitialize)(this.pictureBoxSailboat)).EndInit(); - this.ResumeLayout(false); - this.PerformLayout(); - AutoScaleDimensions = new SizeF(7F, 15F); AutoScaleMode = AutoScaleMode.Font; ClientSize = new Size(834, 461);