PIbd-22 Chubykina P.P. LabWork_07 #10

Closed
chubykina_polina wants to merge 5 commits from LabWork_07 into LabWork_06
3 changed files with 4 additions and 6 deletions
Showing only changes of commit 504ea1e2a3 - Show all commits

View File

@ -74,7 +74,10 @@ namespace Sailboat.Generics
public static T? operator -(BoatsGenericCollection<T, U> collect, int pos)
{
T? obj = collect._collection[pos];
collect._collection.Remove(pos);
if (obj != null)
{
collect._collection.Remove(pos);
}
return obj;
}

View File

@ -184,6 +184,5 @@ namespace Sailboat.Generics
}
}
}
}
}

View File

@ -130,8 +130,6 @@ namespace Sailboat
MessageBox.Show(ex.Message);
_logger.LogWarning($"{ex.Message} из набора {listBoxStorages.SelectedItem.ToString()}");
}
}
private void buttonRefreshCollection_Click(object sender, EventArgs e)
@ -147,7 +145,6 @@ namespace Sailboat
return;
}
pictureBoxCollection.Image = obj.ShowBoats();
}
private void buttonAddObject_Click(object sender, EventArgs e)
@ -222,6 +219,5 @@ namespace Sailboat
}
}
}
}
}