2 Commits

Author SHA1 Message Date
5a4f260e9d LabWork05 2024-05-01 20:24:33 +03:00
713f348d06 LabWork04 2024-04-18 08:10:24 +04:00
10 changed files with 1135 additions and 121 deletions

View File

@@ -0,0 +1,19 @@
namespace ProjectBattleship.CollectionGenericObjects;
/// <summary>
/// Тип коллекции
/// </summary>
public enum CollectionType
{
/// <summary>
/// Неопределено
/// </summary>
None = 0,
/// <summary>
/// Массив
/// </summary>
Massive = 1,
/// <summary>
/// Список
/// </summary>
List = 2
}

View File

@@ -0,0 +1,59 @@
namespace ProjectBattleship.CollectionGenericObjects;
/// <summary>
/// Параметризованный набор объектов
/// </summary>
/// <typeparam name="T">Параметр: ограничение - ссылочный тип</typeparam>
public class ListGenericObjects<T> : ICollectionGenericObjects<T>
where T : class
{
/// <summary>
/// Список объектов, которые храним
/// </summary>
private readonly List<T?> _collection;
/// <summary>
/// Максимально допустимое число объектов в списке
/// </summary>
private int _maxCount;
public int Count => _collection.Count;
public int SetMaxCount { set { if (value > 0) { _maxCount = value; } } }
/// <summary>
/// Конструктор
/// </summary>
public ListGenericObjects()
{
_collection = new();
}
public T? Get(int position)
{
if (position < 0 || position >= Count) return null;
return _collection[position];
}
public int Insert(T? obj)
{
if (Count == _maxCount) return -1;
_collection.Add(obj);
return Count - 1;
}
public int Insert(T? obj, int position)
{
if (Count == _maxCount) return -1;
if (position < 0 || position >= Count) return -1;
_collection.Insert(position, obj);
return position;
}
public T? Remove(int position)
{
if (position < 0 || position >= Count) return null;
T? obj = _collection[position];
_collection.RemoveAt(position);
return obj;
}
}

View File

@@ -0,0 +1,75 @@
namespace ProjectBattleship.CollectionGenericObjects;
/// <summary>
/// Класс-хранилище коллекций
/// </summary>
/// <typeparam name="T"></typeparam>
public class StorageCollection<T>
where T : class
{
/// <summary>
/// Словарь (хранилище) с коллекциями
/// </summary>
readonly Dictionary<string, ICollectionGenericObjects<T>> _storages;
/// <summary>
/// Возвращение списка названий коллекций
/// </summary>
public List<string> Keys => _storages.Keys.ToList();
/// <summary>
/// Конструктор
/// </summary>
public StorageCollection()
{
_storages = new Dictionary<string, ICollectionGenericObjects<T>>();
}
/// <summary>
/// Добавление коллекции в хранилище
/// </summary>
/// <param name="name">Название коллекции</param>
/// <param name="collectionType">тип коллекции</param>
public void AddCollection(string name, CollectionType collectionType)
{
if (string.IsNullOrEmpty(name)) return;
if (_storages.ContainsKey(name)) return;
if (collectionType == CollectionType.None) return;
if (collectionType == CollectionType.Massive)
{
_storages[name] = new MassiveGenericObjects<T>();
}
else if (collectionType == CollectionType.List)
{
_storages[name] = new ListGenericObjects<T>();
}
}
/// <summary>
/// Удаление коллекции
/// </summary>
/// <param name="name">Название коллекции</param>
public void DelCollection(string name)
{
if (_storages.ContainsKey(name))
{
_storages.Remove(name);
}
}
/// <summary>
/// Доступ к коллекции
/// </summary>
/// <param name="name">Название коллекции</param>
/// <returns></returns>
public ICollectionGenericObjects<T>? this[string name]
{
get
{
if (_storages.ContainsKey(name))
{
return _storages[name];
}
return null;
}
}
}

View File

@@ -1,34 +1,19 @@
using ProjectBattleship.Entities;
namespace ProjectBattleship.Entities;
namespace ProjectBattleship.Entities;
/// <summary>
/// Класс-сущность "Линкор"
/// </summary>
public class EntityBattleship : EntityWarship
{
public Color AdditionalColor { get; private set; }
public void SetAdditionalColor(Color color)
{
AdditionalColor = color;
}
public bool Turret { get; private set; }
/// <summary>
/// Признак (опция) наличия отсека под ракеты
/// </summary>
public bool RocketCompartment { get; private set; }
/// <summary>
/// Шаг перемещения корабля
/// </summary>
/// <summary>
/// Инициализация полей объекта-класса спортивного автомобиля
/// </summary>
/// <param name="speed">Скорость</param>
/// <param name="weight">Вес автомобиля</param>
/// <param name="bodyColor">Основной цвет</param>
/// <param name="additionalColor">Дополнительный цвет</param>
/// <param name="turret">Признак наличия орудийной башни</param>
/// <param name="rocketCompartment">Признак наличия отсека под ракеты</param>
public EntityBattleship(int speed, double weight, Color bodyColor, Color additionalColor, bool turret, bool rocketCompartment) : base(speed, weight, bodyColor)
public EntityBattleship(int speed, double weight, Color bodyColor,
Color additionalColor, bool turret, bool rocketCompartment) :
base(speed, weight, bodyColor)
{
AdditionalColor = additionalColor;
Turret = turret;

View File

@@ -4,41 +4,18 @@
/// </summary>
public class EntityWarship
{
/// <summary>
/// Скорость
/// </summary>
public int Speed { get; private set; }
/// <summary>
/// Вес
/// </summary>
public double Weight { get; private set; }
/// <summary>
/// Основной цвет
/// </summary>
public Color BodyColor { get; private set; }
/// <summary>
/// Дополнительный цвет (для опциональных элементов)
/// </summary>
/// <summary>
/// Признак (опция) наличия орудийной башни
/// </summary>
public Color AdditionalColor { get; private set; }
public bool Turret { get; private set; }
/// <summary>
/// Признак (опция) наличия отсека под ракеты
/// </summary>
public bool RocketCompartment { get; private set; }
/// <summary>
/// Шаг перемещения корабля
/// </summary>
public void SetBodyColor(Color color)
{
BodyColor = color;
}
public double Step => Speed * 100 / Weight;
public EntityWarship(int speed, double weight, Color bodyColor)
{
Speed = speed;
Weight = weight;
BodyColor = bodyColor;
}
}

View File

@@ -31,59 +31,102 @@ namespace ProjectBattleship
private void InitializeComponent()
{
groupBoxCollectionTools = new GroupBox();
maskedTextBoxPosition = new MaskedTextBox();
panelCompanyTools = new Panel();
buttonRefresh = new Button();
buttonAddBattleship = new Button();
maskedTextBoxPosition = new MaskedTextBox();
buttonAddWarship = new Button();
buttonGoToCheck = new Button();
buttonRemoveWarship = new Button();
buttonAddBattleship = new Button();
buttonAddWarship = new Button();
buttonCreateCompany = new Button();
comboBoxSelectorCompany = new ComboBox();
panelCollection = new Panel();
buttonCollectionDel = new Button();
listBoxCollection = new ListBox();
buttonCollectionAdd = new Button();
radioButtonList = new RadioButton();
radioButtonMassive = new RadioButton();
textBoxCollectionName = new TextBox();
labelCollection = new Label();
pictureBox = new PictureBox();
groupBoxCollectionTools.SuspendLayout();
panelCompanyTools.SuspendLayout();
panelCollection.SuspendLayout();
((System.ComponentModel.ISupportInitialize)pictureBox).BeginInit();
SuspendLayout();
//
// groupBoxCollectionTools
//
groupBoxCollectionTools.Anchor = AnchorStyles.Top | AnchorStyles.Bottom | AnchorStyles.Right;
groupBoxCollectionTools.Controls.Add(maskedTextBoxPosition);
groupBoxCollectionTools.Controls.Add(buttonRefresh);
groupBoxCollectionTools.Controls.Add(buttonGoToCheck);
groupBoxCollectionTools.Controls.Add(buttonRemoveWarship);
groupBoxCollectionTools.Controls.Add(buttonAddBattleship);
groupBoxCollectionTools.Controls.Add(buttonAddWarship);
groupBoxCollectionTools.Controls.Add(panelCompanyTools);
groupBoxCollectionTools.Controls.Add(buttonCreateCompany);
groupBoxCollectionTools.Controls.Add(comboBoxSelectorCompany);
groupBoxCollectionTools.Location = new Point(777, 0);
groupBoxCollectionTools.Controls.Add(panelCollection);
groupBoxCollectionTools.Location = new Point(694, 0);
groupBoxCollectionTools.Name = "groupBoxCollectionTools";
groupBoxCollectionTools.Size = new Size(196, 594);
groupBoxCollectionTools.Size = new Size(279, 594);
groupBoxCollectionTools.TabIndex = 1;
groupBoxCollectionTools.TabStop = false;
groupBoxCollectionTools.Text = "Инструменты";
//
// maskedTextBoxPosition
// panelCompanyTools
//
maskedTextBoxPosition.Location = new Point(6, 271);
maskedTextBoxPosition.Name = "maskedTextBoxPosition";
maskedTextBoxPosition.Mask = "00";
maskedTextBoxPosition.Size = new Size(183, 31);
maskedTextBoxPosition.TabIndex = 8;
maskedTextBoxPosition.ValidatingType = typeof(int);
panelCompanyTools.Controls.Add(buttonRefresh);
panelCompanyTools.Controls.Add(buttonAddBattleship);
panelCompanyTools.Controls.Add(maskedTextBoxPosition);
panelCompanyTools.Controls.Add(buttonAddWarship);
panelCompanyTools.Controls.Add(buttonGoToCheck);
panelCompanyTools.Controls.Add(buttonRemoveWarship);
panelCompanyTools.Enabled = false;
panelCompanyTools.Location = new Point(6, 348);
panelCompanyTools.Name = "panelCompanyTools";
panelCompanyTools.Size = new Size(267, 240);
panelCompanyTools.TabIndex = 11;
//
// buttonRefresh
//
buttonRefresh.Location = new Point(6, 514);
buttonRefresh.Location = new Point(8, 203);
buttonRefresh.Name = "buttonRefresh";
buttonRefresh.Size = new Size(183, 68);
buttonRefresh.Size = new Size(251, 34);
buttonRefresh.TabIndex = 7;
buttonRefresh.Text = "Обновить";
buttonRefresh.UseVisualStyleBackColor = true;
buttonRefresh.Click += ButtonRefresh_Click;
//
// buttonAddBattleship
//
buttonAddBattleship.Location = new Point(8, 46);
buttonAddBattleship.Name = "buttonAddBattleship";
buttonAddBattleship.Size = new Size(251, 34);
buttonAddBattleship.TabIndex = 3;
buttonAddBattleship.Text = "Добавить линкор";
buttonAddBattleship.UseVisualStyleBackColor = true;
buttonAddBattleship.Click += ButtonAddBattleship_Click;
//
// maskedTextBoxPosition
//
maskedTextBoxPosition.Location = new Point(8, 86);
maskedTextBoxPosition.Mask = "00";
maskedTextBoxPosition.Name = "maskedTextBoxPosition";
maskedTextBoxPosition.Size = new Size(251, 31);
maskedTextBoxPosition.TabIndex = 8;
maskedTextBoxPosition.ValidatingType = typeof(int);
//
// buttonAddWarship
//
buttonAddWarship.Location = new Point(8, 6);
buttonAddWarship.Name = "buttonAddWarship";
buttonAddWarship.Size = new Size(251, 34);
buttonAddWarship.TabIndex = 2;
buttonAddWarship.Text = "Добавить военный корабль";
buttonAddWarship.UseVisualStyleBackColor = true;
buttonAddWarship.Click += ButtonAddWarship_Click;
//
// buttonGoToCheck
//
buttonGoToCheck.Location = new Point(6, 410);
buttonGoToCheck.Location = new Point(8, 163);
buttonGoToCheck.Name = "buttonGoToCheck";
buttonGoToCheck.Size = new Size(183, 68);
buttonGoToCheck.Size = new Size(251, 34);
buttonGoToCheck.TabIndex = 6;
buttonGoToCheck.Text = "Передать на тесты";
buttonGoToCheck.UseVisualStyleBackColor = true;
@@ -91,51 +134,122 @@ namespace ProjectBattleship
//
// buttonRemoveWarship
//
buttonRemoveWarship.Location = new Point(6, 308);
buttonRemoveWarship.Location = new Point(8, 123);
buttonRemoveWarship.Name = "buttonRemoveWarship";
buttonRemoveWarship.Size = new Size(183, 68);
buttonRemoveWarship.Size = new Size(251, 34);
buttonRemoveWarship.TabIndex = 5;
buttonRemoveWarship.Text = "Удалить военный корабль";
buttonRemoveWarship.UseVisualStyleBackColor = true;
buttonRemoveWarship.Click += ButtonRemoveWarship_Click;
//
// buttonAddBattleship
// buttonCreateCompany
//
buttonAddBattleship.Location = new Point(6, 172);
buttonAddBattleship.Name = "buttonAddBattleship";
buttonAddBattleship.Size = new Size(183, 68);
buttonAddBattleship.TabIndex = 3;
buttonAddBattleship.Text = "Добавление линкора";
buttonAddBattleship.UseVisualStyleBackColor = true;
buttonAddBattleship.Click += ButtonAddBattleship_Click;
//
// buttonAddWarship
//
buttonAddWarship.Location = new Point(6, 98);
buttonAddWarship.Name = "buttonAddWarship";
buttonAddWarship.Size = new Size(183, 68);
buttonAddWarship.TabIndex = 2;
buttonAddWarship.Text = "Добавление военного корабля";
buttonAddWarship.UseVisualStyleBackColor = true;
buttonAddWarship.Click += ButtonAddWarship_Click;
buttonCreateCompany.Location = new Point(14, 314);
buttonCreateCompany.Name = "buttonCreateCompany";
buttonCreateCompany.Size = new Size(251, 34);
buttonCreateCompany.TabIndex = 10;
buttonCreateCompany.Text = "Создать компанию";
buttonCreateCompany.UseVisualStyleBackColor = true;
buttonCreateCompany.Click += ButtonCreateCompany_Click;
//
// comboBoxSelectorCompany
//
comboBoxSelectorCompany.FormattingEnabled = true;
comboBoxSelectorCompany.DropDownStyle = ComboBoxStyle.DropDownList;
comboBoxSelectorCompany.Location = new Point(6, 30);
comboBoxSelectorCompany.FormattingEnabled = true;
comboBoxSelectorCompany.Items.AddRange(new object[] { "Хранилище" });
comboBoxSelectorCompany.Location = new Point(14, 275);
comboBoxSelectorCompany.Name = "comboBoxSelectorCompany";
comboBoxSelectorCompany.Size = new Size(183, 33);
comboBoxSelectorCompany.Size = new Size(251, 33);
comboBoxSelectorCompany.TabIndex = 0;
comboBoxSelectorCompany.SelectedIndexChanged += ComboBoxSelectorCompany_SelectedIndexChanged;
//
// panelCollection
//
panelCollection.Controls.Add(buttonCollectionDel);
panelCollection.Controls.Add(listBoxCollection);
panelCollection.Controls.Add(buttonCollectionAdd);
panelCollection.Controls.Add(radioButtonList);
panelCollection.Controls.Add(radioButtonMassive);
panelCollection.Controls.Add(textBoxCollectionName);
panelCollection.Controls.Add(labelCollection);
panelCollection.Location = new Point(6, 25);
panelCollection.Name = "panelCollection";
panelCollection.Size = new Size(267, 246);
panelCollection.TabIndex = 9;
//
// buttonCollectionDel
//
buttonCollectionDel.Location = new Point(8, 210);
buttonCollectionDel.Name = "buttonCollectionDel";
buttonCollectionDel.Size = new Size(251, 34);
buttonCollectionDel.TabIndex = 7;
buttonCollectionDel.Text = "Удалить коллекцию";
buttonCollectionDel.UseVisualStyleBackColor = true;
buttonCollectionDel.Click += ButtonCollectionDel_Click;
//
// listBoxCollection
//
listBoxCollection.FormattingEnabled = true;
listBoxCollection.ItemHeight = 25;
listBoxCollection.Location = new Point(8, 125);
listBoxCollection.Name = "listBoxCollection";
listBoxCollection.Size = new Size(251, 79);
listBoxCollection.TabIndex = 6;
//
// buttonCollectionAdd
//
buttonCollectionAdd.Location = new Point(8, 85);
buttonCollectionAdd.Name = "buttonCollectionAdd";
buttonCollectionAdd.Size = new Size(251, 34);
buttonCollectionAdd.TabIndex = 5;
buttonCollectionAdd.Text = "Добавить коллекцию";
buttonCollectionAdd.UseVisualStyleBackColor = true;
buttonCollectionAdd.Click += ButtonCollectionAdd_Click;
//
// radioButtonList
//
radioButtonList.AutoSize = true;
radioButtonList.Location = new Point(150, 58);
radioButtonList.Name = "radioButtonList";
radioButtonList.Size = new Size(96, 29);
radioButtonList.TabIndex = 4;
radioButtonList.TabStop = true;
radioButtonList.Text = "Список";
radioButtonList.UseVisualStyleBackColor = true;
//
// radioButtonMassive
//
radioButtonMassive.AutoSize = true;
radioButtonMassive.Location = new Point(19, 58);
radioButtonMassive.Name = "radioButtonMassive";
radioButtonMassive.Size = new Size(98, 29);
radioButtonMassive.TabIndex = 3;
radioButtonMassive.TabStop = true;
radioButtonMassive.Text = "Массив";
radioButtonMassive.UseVisualStyleBackColor = true;
//
// textBoxCollectionName
//
textBoxCollectionName.Location = new Point(8, 26);
textBoxCollectionName.Name = "textBoxCollectionName";
textBoxCollectionName.Size = new Size(251, 31);
textBoxCollectionName.TabIndex = 2;
//
// labelCollection
//
labelCollection.AutoSize = true;
labelCollection.Location = new Point(44, 1);
labelCollection.Name = "labelCollection";
labelCollection.Size = new Size(186, 25);
labelCollection.TabIndex = 1;
labelCollection.Text = "Название коллекции:";
//
// pictureBox
//
pictureBox.Anchor = AnchorStyles.Top | AnchorStyles.Bottom | AnchorStyles.Left;
pictureBox.Location = new Point(0, 0);
pictureBox.Name = "pictureBox";
pictureBox.Size = new Size(771, 594);
pictureBox.Size = new Size(688, 594);
pictureBox.TabIndex = 2;
pictureBox.TabStop = false;
//
@@ -144,12 +258,15 @@ namespace ProjectBattleship
AutoScaleDimensions = new SizeF(10F, 25F);
AutoScaleMode = AutoScaleMode.Font;
ClientSize = new Size(978, 594);
Controls.Add(pictureBox);
Controls.Add(groupBoxCollectionTools);
Controls.Add(pictureBox);
Name = "FormWarshipCollection";
Text = "Коллекция военных кораблей";
groupBoxCollectionTools.ResumeLayout(false);
groupBoxCollectionTools.PerformLayout();
panelCompanyTools.ResumeLayout(false);
panelCompanyTools.PerformLayout();
panelCollection.ResumeLayout(false);
panelCollection.PerformLayout();
((System.ComponentModel.ISupportInitialize)pictureBox).EndInit();
ResumeLayout(false);
}
@@ -164,5 +281,15 @@ namespace ProjectBattleship
private Button buttonRemoveWarship;
private MaskedTextBox maskedTextBoxPosition;
private PictureBox pictureBox;
private Panel panelCollection;
private TextBox textBoxCollectionName;
private Label labelCollection;
private Button buttonCollectionAdd;
private RadioButton radioButtonList;
private RadioButton radioButtonMassive;
private Button buttonCreateCompany;
private Button buttonCollectionDel;
private ListBox listBoxCollection;
private Panel panelCompanyTools;
}
}

View File

@@ -7,6 +7,10 @@ namespace ProjectBattleship;
/// </summary>
public partial class FormWarshipCollection : Form
{
/// <summary>
/// Хранилише коллекций
/// </summary>
private readonly StorageCollection<DrawingWarship> _storageCollection;
/// <summary>
/// Компания
/// </summary>
@@ -17,37 +21,55 @@ public partial class FormWarshipCollection : Form
public FormWarshipCollection()
{
InitializeComponent();
_storageCollection = new();
}
/// <summary>
/// Выбор компании
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void ComboBoxSelectorCompany_SelectedIndexChanged(object sender,
EventArgs e)
private void ComboBoxSelectorCompany_SelectedIndexChanged(object sender,
EventArgs e)
{
switch (comboBoxSelectorCompany.Text)
{
case "Хранилище":
_company = new Docks(pictureBox.Width,
pictureBox.Height,
new MassiveGenericObjects<DrawingWarship>());
break;
}
panelCompanyTools.Enabled = false;
}
/// <summary>
/// Добавление военного корабля
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void ButtonAddWarship_Click(object sender, EventArgs e) =>
CreateObject(nameof(DrawingWarship));
private void ButtonAddWarship_Click(object sender, EventArgs e)
{
FormWarshipConfig form = new();
form.Show();
form.AddEvent(SetWarship);
}
/// <summary>
/// Добавление военного корабля в коллекцию
/// </summary>
/// <param name="car"></param>
private void SetWarship(DrawingWarship? warship)
{
if (_company == null || warship == null)
{
return;
}
if (_company + warship != -1)
{
MessageBox.Show("Объект добавлен");
pictureBox.Image = _company.Show();
}
else
{
MessageBox.Show("Не удалось добавить объект");
}
}
/// <summary>
/// Добавление линкора
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void ButtonAddBattleship_Click(object sender, EventArgs e) =>
private void ButtonAddBattleship_Click(object sender, EventArgs e) =>
CreateObject(nameof(DrawingBattleship));
/// <summary>
/// Создание объекта класса-перемещения
@@ -64,15 +86,15 @@ public partial class FormWarshipCollection : Form
switch (type)
{
case nameof(DrawingWarship):
drawingWarship = new DrawingWarship(random.Next(100, 300),
random.Next(1000, 3000), GetColor(random));
drawingWarship = new DrawingWarship(random.Next(100, 300),
random.Next(1000, 3000), GetColor(random));
break;
case nameof(DrawingBattleship):
drawingWarship = new DrawingBattleship(random.Next(100, 300),
random.Next(1000, 3000),
GetColor(random), GetColor(random),
Convert.ToBoolean(random.Next(0, 2)),
Convert.ToBoolean(random.Next(0, 2)));
GetColor(random), GetColor(random),
Convert.ToBoolean(random.Next(0, 2)),
Convert.ToBoolean(random.Next(0, 2)));
break;
default:
return;
@@ -110,14 +132,13 @@ public partial class FormWarshipCollection : Form
/// <param name="e"></param>
private void ButtonRemoveWarship_Click(object sender, EventArgs e)
{
if (string.IsNullOrEmpty(maskedTextBoxPosition.Text) ||
_company == null)
if (string.IsNullOrEmpty(maskedTextBoxPosition.Text)
|| _company == null)
{
return;
}
if (MessageBox.Show("Удалить объект?", "Удаление",
MessageBoxButtons.YesNo, MessageBoxIcon.Question)
!= DialogResult.Yes)
MessageBoxButtons.YesNo, MessageBoxIcon.Question) != DialogResult.Yes)
{
return;
}
@@ -177,5 +198,98 @@ public partial class FormWarshipCollection : Form
}
pictureBox.Image = _company.Show();
}
/// <summary>
/// Добавление коллекции
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void ButtonCollectionAdd_Click(object sender, EventArgs e)
{
if (string.IsNullOrEmpty(textBoxCollectionName.Text) ||
(!radioButtonList.Checked && !radioButtonMassive.Checked))
{
MessageBox.Show("Не все данные заполнены", "Ошибка",
MessageBoxButtons.OK, MessageBoxIcon.Error);
return;
}
CollectionType collectionType = CollectionType.None;
if (radioButtonMassive.Checked)
{
collectionType = CollectionType.Massive;
}
else if (radioButtonList.Checked)
{
collectionType = CollectionType.List;
}
_storageCollection.AddCollection(textBoxCollectionName.Text,
collectionType);
RerfreshListBoxItems();
}
/// <summary>
/// Удаление коллекции
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void ButtonCollectionDel_Click(object sender, EventArgs e)
{
if (listBoxCollection.SelectedIndex < 0 || listBoxCollection.SelectedItem == null)
{
MessageBox.Show("Коллекция не выбрана");
return;
}
if (MessageBox.Show("Вы хотите удалить эту коллекцию?", "Удаление", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes)
{
string? name = listBoxCollection.SelectedItem.ToString();
if (!string.IsNullOrEmpty(name))
{
_storageCollection.DelCollection(name);
}
}
RerfreshListBoxItems();
}
/// <summary>
/// Обновление списка в listBoxCollection
/// </summary>
private void RerfreshListBoxItems()
{
listBoxCollection.Items.Clear();
for (int i = 0; i < _storageCollection.Keys?.Count; ++i)
{
string? colName = _storageCollection.Keys?[i];
if (!string.IsNullOrEmpty(colName))
{
listBoxCollection.Items.Add(colName);
}
}
}
/// <summary>
/// Создание компании
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void ButtonCreateCompany_Click(object sender, EventArgs e)
{
if (listBoxCollection.SelectedIndex < 0 ||
listBoxCollection.SelectedItem == null)
{
MessageBox.Show("Коллекция не выбрана");
return;
}
ICollectionGenericObjects<DrawingWarship>? collection =
_storageCollection[listBoxCollection.SelectedItem.ToString() ?? string.Empty];
if (collection == null)
{
MessageBox.Show("Коллекция не проинициализирована");
return;
}
switch (comboBoxSelectorCompany.Text)
{
case "Хранилище":
_company = new Docks(pictureBox.Width,
pictureBox.Height, collection);
break;
}
panelCompanyTools.Enabled = true;
RerfreshListBoxItems();
}
}

View File

@@ -0,0 +1,360 @@
namespace ProjectBattleship
{
partial class FormWarshipConfig
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
groupBoxConfig = new GroupBox();
groupBoxColors = new GroupBox();
panelPurple = new Panel();
panelBlack = new Panel();
panelGray = new Panel();
panelWhite = new Panel();
panelYellow = new Panel();
panelBlue = new Panel();
panelGreen = new Panel();
panelRed = new Panel();
checkBoxRocketCompartment = new CheckBox();
checkBoxTurret = new CheckBox();
numericUpDownWeight = new NumericUpDown();
labelWeight = new Label();
numericUpDownSpeed = new NumericUpDown();
labelSpeed = new Label();
labelModifiedObject = new Label();
labelSimpleObject = new Label();
pictureBoxObject = new PictureBox();
buttonAdd = new Button();
buttonCancel = new Button();
panelObject = new Panel();
labelAdditionalColor = new Label();
labelBodyColor = new Label();
groupBoxConfig.SuspendLayout();
groupBoxColors.SuspendLayout();
((System.ComponentModel.ISupportInitialize)numericUpDownWeight).BeginInit();
((System.ComponentModel.ISupportInitialize)numericUpDownSpeed).BeginInit();
((System.ComponentModel.ISupportInitialize)pictureBoxObject).BeginInit();
panelObject.SuspendLayout();
SuspendLayout();
//
// groupBoxConfig
//
groupBoxConfig.Controls.Add(groupBoxColors);
groupBoxConfig.Controls.Add(checkBoxRocketCompartment);
groupBoxConfig.Controls.Add(checkBoxTurret);
groupBoxConfig.Controls.Add(numericUpDownWeight);
groupBoxConfig.Controls.Add(labelWeight);
groupBoxConfig.Controls.Add(numericUpDownSpeed);
groupBoxConfig.Controls.Add(labelSpeed);
groupBoxConfig.Controls.Add(labelModifiedObject);
groupBoxConfig.Controls.Add(labelSimpleObject);
groupBoxConfig.Dock = DockStyle.Left;
groupBoxConfig.Location = new Point(0, 0);
groupBoxConfig.Name = "groupBoxConfig";
groupBoxConfig.Size = new Size(671, 379);
groupBoxConfig.TabIndex = 0;
groupBoxConfig.TabStop = false;
groupBoxConfig.Text = "Параметры";
//
// groupBoxColors
//
groupBoxColors.Controls.Add(panelPurple);
groupBoxColors.Controls.Add(panelBlack);
groupBoxColors.Controls.Add(panelGray);
groupBoxColors.Controls.Add(panelWhite);
groupBoxColors.Controls.Add(panelYellow);
groupBoxColors.Controls.Add(panelBlue);
groupBoxColors.Controls.Add(panelGreen);
groupBoxColors.Controls.Add(panelRed);
groupBoxColors.Location = new Point(300, 30);
groupBoxColors.Name = "groupBoxColors";
groupBoxColors.Size = new Size(345, 195);
groupBoxColors.TabIndex = 8;
groupBoxColors.TabStop = false;
groupBoxColors.Text = "Цвета";
//
// panelPurple
//
panelPurple.BackColor = Color.MediumPurple;
panelPurple.Location = new Point(271, 112);
panelPurple.Name = "panelPurple";
panelPurple.Size = new Size(62, 56);
panelPurple.TabIndex = 7;
//
// panelBlack
//
panelBlack.BackColor = Color.Black;
panelBlack.Location = new Point(182, 112);
panelBlack.Name = "panelBlack";
panelBlack.Size = new Size(62, 56);
panelBlack.TabIndex = 6;
//
// panelGray
//
panelGray.BackColor = Color.LightGray;
panelGray.Location = new Point(94, 112);
panelGray.Name = "panelGray";
panelGray.Size = new Size(62, 56);
panelGray.TabIndex = 5;
//
// panelWhite
//
panelWhite.BackColor = Color.White;
panelWhite.Location = new Point(7, 112);
panelWhite.Name = "panelWhite";
panelWhite.Size = new Size(62, 56);
panelWhite.TabIndex = 4;
//
// panelYellow
//
panelYellow.BackColor = Color.Yellow;
panelYellow.Location = new Point(271, 30);
panelYellow.Name = "panelYellow";
panelYellow.Size = new Size(62, 56);
panelYellow.TabIndex = 3;
//
// panelBlue
//
panelBlue.BackColor = Color.Blue;
panelBlue.Location = new Point(182, 30);
panelBlue.Name = "panelBlue";
panelBlue.Size = new Size(62, 56);
panelBlue.TabIndex = 2;
//
// panelGreen
//
panelGreen.BackColor = Color.Green;
panelGreen.Location = new Point(94, 30);
panelGreen.Name = "panelGreen";
panelGreen.Size = new Size(62, 56);
panelGreen.TabIndex = 1;
//
// panelRed
//
panelRed.BackColor = Color.Red;
panelRed.Location = new Point(7, 30);
panelRed.Name = "panelRed";
panelRed.Size = new Size(62, 56);
panelRed.TabIndex = 0;
//
// checkBoxRocketCompartment
//
checkBoxRocketCompartment.AutoSize = true;
checkBoxRocketCompartment.Location = new Point(14, 277);
checkBoxRocketCompartment.Name = "checkBoxRocketCompartment";
checkBoxRocketCompartment.Size = new Size(337, 29);
checkBoxRocketCompartment.TabIndex = 7;
checkBoxRocketCompartment.Text = "Признак наличия отсека под ракеты";
checkBoxRocketCompartment.UseVisualStyleBackColor = true;
//
// checkBoxTurret
//
checkBoxTurret.AutoSize = true;
checkBoxTurret.Location = new Point(14, 231);
checkBoxTurret.Name = "checkBoxTurret";
checkBoxTurret.Size = new Size(335, 29);
checkBoxTurret.TabIndex = 6;
checkBoxTurret.Text = "Признак наличия орудийной башни";
checkBoxTurret.UseVisualStyleBackColor = true;
//
// numericUpDownWeight
//
numericUpDownWeight.Location = new Point(111, 82);
numericUpDownWeight.Maximum = new decimal(new int[] { 1000, 0, 0, 0 });
numericUpDownWeight.Minimum = new decimal(new int[] { 100, 0, 0, 0 });
numericUpDownWeight.Name = "numericUpDownWeight";
numericUpDownWeight.Size = new Size(120, 31);
numericUpDownWeight.TabIndex = 5;
numericUpDownWeight.Value = new decimal(new int[] { 100, 0, 0, 0 });
//
// labelWeight
//
labelWeight.AutoSize = true;
labelWeight.Location = new Point(12, 82);
labelWeight.Name = "labelWeight";
labelWeight.Size = new Size(43, 25);
labelWeight.TabIndex = 4;
labelWeight.Text = "Вес:";
//
// numericUpDownSpeed
//
numericUpDownSpeed.Location = new Point(111, 30);
numericUpDownSpeed.Maximum = new decimal(new int[] { 1000, 0, 0, 0 });
numericUpDownSpeed.Minimum = new decimal(new int[] { 100, 0, 0, 0 });
numericUpDownSpeed.Name = "numericUpDownSpeed";
numericUpDownSpeed.Size = new Size(120, 31);
numericUpDownSpeed.TabIndex = 3;
numericUpDownSpeed.Value = new decimal(new int[] { 100, 0, 0, 0 });
//
// labelSpeed
//
labelSpeed.AutoSize = true;
labelSpeed.Location = new Point(12, 32);
labelSpeed.Name = "labelSpeed";
labelSpeed.Size = new Size(93, 25);
labelSpeed.TabIndex = 2;
labelSpeed.Text = "Скорость:";
//
// labelModifiedObject
//
labelModifiedObject.BorderStyle = BorderStyle.FixedSingle;
labelModifiedObject.Location = new Point(482, 319);
labelModifiedObject.Name = "labelModifiedObject";
labelModifiedObject.Size = new Size(163, 38);
labelModifiedObject.TabIndex = 1;
labelModifiedObject.Text = "Продвинутый";
labelModifiedObject.TextAlign = ContentAlignment.MiddleCenter;
labelModifiedObject.MouseDown += LabelObject_MouseDown;
//
// labelSimpleObject
//
labelSimpleObject.BorderStyle = BorderStyle.FixedSingle;
labelSimpleObject.Location = new Point(300, 319);
labelSimpleObject.Name = "labelSimpleObject";
labelSimpleObject.Size = new Size(162, 38);
labelSimpleObject.TabIndex = 0;
labelSimpleObject.Text = "Простой";
labelSimpleObject.TextAlign = ContentAlignment.MiddleCenter;
labelSimpleObject.MouseDown += LabelObject_MouseDown;
//
// pictureBoxObject
//
pictureBoxObject.Location = new Point(46, 92);
pictureBoxObject.Name = "pictureBoxObject";
pictureBoxObject.Size = new Size(252, 175);
pictureBoxObject.TabIndex = 1;
pictureBoxObject.TabStop = false;
//
// buttonAdd
//
buttonAdd.Location = new Point(707, 323);
buttonAdd.Name = "buttonAdd";
buttonAdd.Size = new Size(112, 34);
buttonAdd.TabIndex = 2;
buttonAdd.Text = "Добавить";
buttonAdd.UseVisualStyleBackColor = true;
buttonAdd.Click += ButtonAdd_Click;
//
// buttonCancel
//
buttonCancel.Location = new Point(911, 323);
buttonCancel.Name = "buttonCancel";
buttonCancel.Size = new Size(112, 34);
buttonCancel.TabIndex = 3;
buttonCancel.Text = "Отмена";
buttonCancel.UseVisualStyleBackColor = true;
//
// panelObject
//
panelObject.AllowDrop = true;
panelObject.Controls.Add(labelAdditionalColor);
panelObject.Controls.Add(labelBodyColor);
panelObject.Controls.Add(pictureBoxObject);
panelObject.Location = new Point(691, 12);
panelObject.Name = "panelObject";
panelObject.Size = new Size(343, 294);
panelObject.TabIndex = 0;
panelObject.DragDrop += PanelObject_DragDrop;
panelObject.DragEnter += PanelObject_DragEnter;
//
// labelAdditionalColor
//
labelAdditionalColor.AllowDrop = true;
labelAdditionalColor.AutoSize = true;
labelAdditionalColor.BorderStyle = BorderStyle.FixedSingle;
labelAdditionalColor.Location = new Point(220, 18);
labelAdditionalColor.Name = "labelAdditionalColor";
labelAdditionalColor.Size = new Size(93, 27);
labelAdditionalColor.TabIndex = 3;
labelAdditionalColor.Text = "Доп. цвет";
labelAdditionalColor.TextAlign = ContentAlignment.MiddleCenter;
labelAdditionalColor.DragDrop += LabelAdditionalColor_DragDrop;
labelAdditionalColor.DragEnter += LabelAdditionalColor_DragEnter;
//
// labelBodyColor
//
labelBodyColor.AllowDrop = true;
labelBodyColor.AutoSize = true;
labelBodyColor.BorderStyle = BorderStyle.FixedSingle;
labelBodyColor.Location = new Point(46, 22);
labelBodyColor.Name = "labelBodyColor";
labelBodyColor.Size = new Size(53, 27);
labelBodyColor.TabIndex = 2;
labelBodyColor.Text = "Цвет";
labelBodyColor.TextAlign = ContentAlignment.MiddleCenter;
labelBodyColor.DragDrop += LabelBodyColor_DragDrop;
labelBodyColor.DragEnter += LabelBodyColor_DragEnter;
//
// FormWarshipConfig
//
AutoScaleDimensions = new SizeF(10F, 25F);
AutoScaleMode = AutoScaleMode.Font;
ClientSize = new Size(1046, 379);
Controls.Add(panelObject);
Controls.Add(buttonCancel);
Controls.Add(buttonAdd);
Controls.Add(groupBoxConfig);
Name = "FormWarshipConfig";
Text = "Создание объекта";
groupBoxConfig.ResumeLayout(false);
groupBoxConfig.PerformLayout();
groupBoxColors.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)numericUpDownWeight).EndInit();
((System.ComponentModel.ISupportInitialize)numericUpDownSpeed).EndInit();
((System.ComponentModel.ISupportInitialize)pictureBoxObject).EndInit();
panelObject.ResumeLayout(false);
panelObject.PerformLayout();
ResumeLayout(false);
}
#endregion
private GroupBox groupBoxConfig;
private Label labelSimpleObject;
private Label labelSpeed;
private Label labelModifiedObject;
private Label labelWeight;
private NumericUpDown numericUpDownSpeed;
private NumericUpDown numericUpDownWeight;
private CheckBox checkBoxTurret;
private CheckBox checkBoxRocketCompartment;
private GroupBox groupBoxColors;
private Panel panelRed;
private Panel panelPurple;
private Panel panelBlack;
private Panel panelGray;
private Panel panelWhite;
private Panel panelYellow;
private Panel panelBlue;
private Panel panelGreen;
private PictureBox pictureBoxObject;
private Button buttonAdd;
private Button buttonCancel;
private Panel panelObject;
private Label labelAdditionalColor;
private Label labelBodyColor;
}
}

View File

@@ -0,0 +1,178 @@
using ProjectBattleship.DrawingObject;
using ProjectBattleship.Entities;
namespace ProjectBattleship
{
/// <summary>
/// Форма конфигурации объекта
/// </summary>
public partial class FormWarshipConfig : Form
{
/// <summary>
/// Объект - прорисовка
/// </summary>
private DrawingWarship? _warship;
/// <summary>
/// Событие для передачи объекта
/// </summary>
private event Action<DrawingWarship>? WarshipDelegate;
/// <summary>
/// Конструктор
/// </summary>
public FormWarshipConfig()
{
InitializeComponent();
panelRed.MouseDown += Panel_MouseDown;
panelGreen.MouseDown += Panel_MouseDown;
panelBlue.MouseDown += Panel_MouseDown;
panelYellow.MouseDown += Panel_MouseDown;
panelWhite.MouseDown += Panel_MouseDown;
panelGray.MouseDown += Panel_MouseDown;
panelBlack.MouseDown += Panel_MouseDown;
panelPurple.MouseDown += Panel_MouseDown;
buttonCancel.Click += (sender, e) => Close();
}
/// <summary>
/// Привязка внешнего метода к событию
/// </summary>
/// <param name="WarshipDelegate"></param>
public void AddEvent(Action<DrawingWarship> warshipDelegate)
{
if (WarshipDelegate != null)
{
WarshipDelegate = warshipDelegate;
}
else
{
WarshipDelegate += warshipDelegate;
}
}
/// <summary>
/// Прорисовка объекта
/// </summary>
private void DrawObject()
{
Bitmap bmp = new(pictureBoxObject.Width, pictureBoxObject.Height);
Graphics gr = Graphics.FromImage(bmp);
_warship?.SetPictureSize(pictureBoxObject.Width,
pictureBoxObject.Height);
_warship?.SetPosition(15, 15);
_warship?.DrawTransport(gr);
pictureBoxObject.Image = bmp;
}
/// <summary>
/// Передаем информацию при нажатии на Label
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void LabelObject_MouseDown(object sender, MouseEventArgs e)
{
(sender as Label)?.DoDragDrop((sender as Label)?.Name ??
string.Empty, DragDropEffects.Move | DragDropEffects.Copy);
}
/// <summary>
/// Проверка получаемой информации (ее типа на соответствие требуемому)
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void PanelObject_DragEnter(object sender, DragEventArgs e)
{
e.Effect = e.Data?.GetDataPresent(DataFormats.Text) ?? false ?
DragDropEffects.Copy : DragDropEffects.None;
}
/// <summary>
/// Действия при приеме перетаскиваемой информации
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void PanelObject_DragDrop(object sender, DragEventArgs e)
{
switch (e.Data?.GetData(DataFormats.Text)?.ToString())
{
case "labelSimpleObject":
_warship = new DrawingWarship((int)numericUpDownSpeed.Value,
(double)numericUpDownWeight.Value, Color.White);
break;
case "labelModifiedObject":
_warship = new
DrawingBattleship((int)numericUpDownSpeed.Value,
(double)numericUpDownWeight.Value,
Color.White, Color.Black, checkBoxTurret.Checked,
checkBoxRocketCompartment.Checked);
break;
}
DrawObject();
}
/// <summary>
/// Передаем информацию при нажатии на Panel
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void Panel_MouseDown(object? sender, MouseEventArgs e)
{
(sender as Control)?.DoDragDrop((sender as Control).BackColor, DragDropEffects.Move | DragDropEffects.Copy);
}
private void LabelBodyColor_DragEnter(object sender, DragEventArgs e)
{
if (e.Data?.GetDataPresent(typeof(Color)) ?? false)
{
e.Effect = DragDropEffects.Copy;
}
else
{
e.Effect = DragDropEffects.None;
}
}
private void LabelBodyColor_DragDrop(object sender, DragEventArgs e)
{
if (_warship != null)
{
if (e.Data?.GetDataPresent(typeof(Color)) ?? false)
{
_warship.EntityWarship.SetBodyColor((Color)e.Data.GetData(typeof(Color)));
}
DrawObject();
}
}
private void LabelAdditionalColor_DragEnter(object sender, DragEventArgs e)
{
if (_warship != null && _warship is DrawingBattleship)
{
if (e.Data?.GetDataPresent(typeof(Color)) ?? false)
{
e.Effect = DragDropEffects.Copy;
}
else
{
e.Effect = DragDropEffects.None;
}
}
}
private void LabelAdditionalColor_DragDrop(object sender, DragEventArgs e)
{
if (_warship != null && _warship.EntityWarship is EntityBattleship _battleship)
{
if (e.Data.GetDataPresent(typeof(Color)))
{
_battleship.SetAdditionalColor((Color)e.Data.GetData(typeof(Color)));
}
DrawObject();
}
}
private void ButtonAdd_Click(object sender, EventArgs e)
{
if (_warship != null)
{
WarshipDelegate?.Invoke(_warship);
Close();
}
}
}
}

View File

@@ -0,0 +1,120 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing"">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>