Изменил(а) на 'HoistingCrane/HoistingCrane/FormMapWithSetHoistingCrane.cs'

This commit is contained in:
RomanovEgor 2022-11-06 17:40:07 +04:00
parent 9ab984f93d
commit 4d57b0951b

View File

@ -135,8 +135,8 @@ namespace HoistingCrane
FormHoistingCrane form = new(); FormHoistingCrane form = new();
if (form.ShowDialog() == DialogResult.OK) if (form.ShowDialog() == DialogResult.OK)
{ {
DrawingObjectHoistingCrane roadtrain = new(form.SelectedHoistingCrane); DrawingObjectHoistingCrane hoistingCrane = new(form.SelectedHoistingCrane);
if (_mapsCollection[listBoxMaps.SelectedItem?.ToString() ?? string.Empty] + roadtrain != -1) if (_mapsCollection[listBoxMaps.SelectedItem?.ToString() ?? string.Empty] + hoistingCrane != -1)
{ {
MessageBox.Show("Объект добавлен"); MessageBox.Show("Объект добавлен");
pictureBox.Image = _mapsCollection[listBoxMaps.SelectedItem?.ToString() ?? string.Empty].ShowSet(); pictureBox.Image = _mapsCollection[listBoxMaps.SelectedItem?.ToString() ?? string.Empty].ShowSet();
@ -176,7 +176,7 @@ namespace HoistingCrane
{ {
return; return;
} }
pictureBox.Image = _mapsCollection[listBoxMaps.SelectedItem?.ToString() ?? string.Empty].ShowOnMap(); pictureBox.Image = _mapsCollection[listBoxMaps.SelectedItem?.ToString() ?? string.Empty].ShowSet();
} }
private void ButtonShowOnMap_Click(object sender, EventArgs e) private void ButtonShowOnMap_Click(object sender, EventArgs e)