Karamushko M.K lab3_base #5

Closed
maxKarme wants to merge 2 commits from lab3_base into lab2_base
2 changed files with 65 additions and 61 deletions
Showing only changes of commit 2fc394b825 - Show all commits

View File

@ -29,6 +29,10 @@
private void InitializeComponent()
{
this.tools = new System.Windows.Forms.GroupBox();
this.RightButton = new System.Windows.Forms.Button();
this.LeftButton = new System.Windows.Forms.Button();
this.UpButton = new System.Windows.Forms.Button();
this.DownButton = new System.Windows.Forms.Button();
this.maskedTextBoxPosition = new System.Windows.Forms.MaskedTextBox();
this.buttonRemove = new System.Windows.Forms.Button();
this.ButtonShowOnMap = new System.Windows.Forms.Button();
@ -36,10 +40,6 @@
this.buttonAdd = new System.Windows.Forms.Button();
this.comboBoxSelectorMap = new System.Windows.Forms.ComboBox();
this.pictureBox = new System.Windows.Forms.PictureBox();
this.RightButton = new System.Windows.Forms.Button();
this.LeftButton = new System.Windows.Forms.Button();
this.UpButton = new System.Windows.Forms.Button();
this.DownButton = new System.Windows.Forms.Button();
this.tools.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.pictureBox)).BeginInit();
this.SuspendLayout();
@ -57,13 +57,65 @@
this.tools.Controls.Add(this.buttonAdd);
this.tools.Controls.Add(this.comboBoxSelectorMap);
this.tools.Dock = System.Windows.Forms.DockStyle.Right;
this.tools.Location = new System.Drawing.Point(550, 0);
this.tools.Location = new System.Drawing.Point(839, 0);
this.tools.Name = "tools";
this.tools.Size = new System.Drawing.Size(250, 450);
this.tools.Size = new System.Drawing.Size(250, 597);
this.tools.TabIndex = 0;
this.tools.TabStop = false;
this.tools.Text = "Инструменты";
//
// RightButton
//
this.RightButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.RightButton.BackgroundImage = global::AirFighter.Properties.Resources.right;
this.RightButton.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch;
this.RightButton.Location = new System.Drawing.Point(148, 555);
this.RightButton.Name = "RightButton";
this.RightButton.RightToLeft = System.Windows.Forms.RightToLeft.No;
this.RightButton.Size = new System.Drawing.Size(30, 30);
this.RightButton.TabIndex = 9;
this.RightButton.UseVisualStyleBackColor = true;
this.RightButton.Click += new System.EventHandler(this.ButtonMove_Click);
//
// LeftButton
//
this.LeftButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.LeftButton.BackgroundImage = global::AirFighter.Properties.Resources.left;
this.LeftButton.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch;
this.LeftButton.Location = new System.Drawing.Point(76, 555);
this.LeftButton.Name = "LeftButton";
this.LeftButton.RightToLeft = System.Windows.Forms.RightToLeft.No;
this.LeftButton.Size = new System.Drawing.Size(30, 30);
this.LeftButton.TabIndex = 8;
this.LeftButton.UseVisualStyleBackColor = true;
this.LeftButton.Click += new System.EventHandler(this.ButtonMove_Click);
//
// UpButton
//
this.UpButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.UpButton.BackgroundImage = global::AirFighter.Properties.Resources.up;
this.UpButton.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch;
this.UpButton.Location = new System.Drawing.Point(112, 520);
this.UpButton.Name = "UpButton";
this.UpButton.RightToLeft = System.Windows.Forms.RightToLeft.No;
this.UpButton.Size = new System.Drawing.Size(30, 30);
this.UpButton.TabIndex = 7;
this.UpButton.UseVisualStyleBackColor = true;
this.UpButton.Click += new System.EventHandler(this.ButtonMove_Click);
//
// DownButton
//
this.DownButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.DownButton.BackgroundImage = global::AirFighter.Properties.Resources.down;
this.DownButton.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch;
this.DownButton.Location = new System.Drawing.Point(112, 555);
this.DownButton.Name = "DownButton";
this.DownButton.RightToLeft = System.Windows.Forms.RightToLeft.No;
this.DownButton.Size = new System.Drawing.Size(30, 30);
this.DownButton.TabIndex = 6;
this.DownButton.UseVisualStyleBackColor = true;
this.DownButton.Click += new System.EventHandler(this.ButtonMove_Click);
//
// maskedTextBoxPosition
//
this.maskedTextBoxPosition.Location = new System.Drawing.Point(3, 145);
@ -117,7 +169,8 @@
this.comboBoxSelectorMap.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.comboBoxSelectorMap.FormattingEnabled = true;
this.comboBoxSelectorMap.Items.AddRange(new object[] {
"Простая карта"});
"Простая карта",
"Моя карта"});
this.comboBoxSelectorMap.Location = new System.Drawing.Point(3, 23);
this.comboBoxSelectorMap.Name = "comboBoxSelectorMap";
this.comboBoxSelectorMap.Size = new System.Drawing.Size(235, 28);
@ -129,67 +182,15 @@
this.pictureBox.Dock = System.Windows.Forms.DockStyle.Fill;
this.pictureBox.Location = new System.Drawing.Point(0, 0);
this.pictureBox.Name = "pictureBox";
this.pictureBox.Size = new System.Drawing.Size(550, 450);
this.pictureBox.Size = new System.Drawing.Size(839, 597);
this.pictureBox.TabIndex = 1;
this.pictureBox.TabStop = false;
//
// RightButton
//
this.RightButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.RightButton.BackgroundImage = global::AirFighter.Properties.Resources.right;
this.RightButton.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch;
this.RightButton.Location = new System.Drawing.Point(148, 408);
this.RightButton.Name = "RightButton";
this.RightButton.RightToLeft = System.Windows.Forms.RightToLeft.No;
this.RightButton.Size = new System.Drawing.Size(30, 30);
this.RightButton.TabIndex = 9;
this.RightButton.UseVisualStyleBackColor = true;
this.RightButton.Click += new System.EventHandler(this.ButtonMove_Click);
//
// LeftButton
//
this.LeftButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.LeftButton.BackgroundImage = global::AirFighter.Properties.Resources.left;
this.LeftButton.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch;
this.LeftButton.Location = new System.Drawing.Point(76, 408);
this.LeftButton.Name = "LeftButton";
this.LeftButton.RightToLeft = System.Windows.Forms.RightToLeft.No;
this.LeftButton.Size = new System.Drawing.Size(30, 30);
this.LeftButton.TabIndex = 8;
this.LeftButton.UseVisualStyleBackColor = true;
this.LeftButton.Click += new System.EventHandler(this.ButtonMove_Click);
//
// UpButton
//
this.UpButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.UpButton.BackgroundImage = global::AirFighter.Properties.Resources.up;
this.UpButton.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch;
this.UpButton.Location = new System.Drawing.Point(112, 373);
this.UpButton.Name = "UpButton";
this.UpButton.RightToLeft = System.Windows.Forms.RightToLeft.No;
this.UpButton.Size = new System.Drawing.Size(30, 30);
this.UpButton.TabIndex = 7;
this.UpButton.UseVisualStyleBackColor = true;
this.UpButton.Click += new System.EventHandler(this.ButtonMove_Click);
//
// DownButton
//
this.DownButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.DownButton.BackgroundImage = global::AirFighter.Properties.Resources.down;
this.DownButton.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch;
this.DownButton.Location = new System.Drawing.Point(112, 408);
this.DownButton.Name = "DownButton";
this.DownButton.RightToLeft = System.Windows.Forms.RightToLeft.No;
this.DownButton.Size = new System.Drawing.Size(30, 30);
this.DownButton.TabIndex = 6;
this.DownButton.UseVisualStyleBackColor = true;
this.DownButton.Click += new System.EventHandler(this.ButtonMove_Click);
//
// FormMapWithSetCars
//
this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 20F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(800, 450);
this.ClientSize = new System.Drawing.Size(1089, 597);
this.Controls.Add(this.pictureBox);
this.Controls.Add(this.tools);
this.Name = "FormMapWithSetCars";

View File

@ -33,6 +33,9 @@ namespace AirFighter
case "Простая карта":
map = new SimpleMap();
break;
case "Моя карта":
map = new MyMap();
break;
}
if (map != null)
{