Polevoy S.V Lab_work5 #5

Merged
eegov merged 4 commits from LabWork05 into LabWork04 2022-10-28 09:27:37 +04:00
2 changed files with 6 additions and 2 deletions
Showing only changes of commit 3cee8a2eab - Show all commits

View File

@ -118,6 +118,5 @@ namespace Artilleries
EventAddArtillery?.Invoke(_artillery);
Close();
}
}
}

View File

@ -89,7 +89,12 @@ namespace Artilleries
private void buttonAddArtillery_Click(object sender, EventArgs e)
{
var formArtilleryConfig = new FormArtilleryConfig();
formArtilleryConfig.AddEvent((artillery) => {
formArtilleryConfig.AddEvent((artillery) => {
if (listBoxMaps.SelectedIndex == -1)
{
return;
}
if (_mapsCollection[listBoxMaps.SelectedItem?.ToString() ?? String.Empty] + new DrawingObjectArtillery(artillery) != -1)
{
MessageBox.Show("Объект добавлен");