private void ButSave_Click(object sender, EventArgs e) { if (receivedYacht == null) { Yacht yacht = new Yacht(); yacht.TypeName = TypeNames.yacht; EditYacht(yacht); FMain.AddVehicle(yacht); } else { EditYacht(receivedYacht); } Close(); }
private void ButSave_Click(object sender, EventArgs e) { if (receivedPlane == null) { Plane plane = new Plane(); plane.TypeName = TypeNames.plane; EditPlane(plane); FMain.AddVehicle(plane); } else { EditPlane(receivedPlane); } Close(); }
private void ButSave_Click(object sender, EventArgs e) { if (receivedAirship == null) { Airship airship = new Airship(); airship.TypeName = TypeNames.airship; EditAirship(airship); FMain.AddVehicle(airship); } else { EditAirship(receivedAirship); } Close(); }
private void ButSave_Click(object sender, EventArgs e) { if (receivedAuto == null) { Auto auto = new Auto(); auto.TypeName = TypeNames.auto; EditAuto(auto); FMain.AddVehicle(auto); } else { EditAuto(receivedAuto); } Close(); }
private void ButSave_Click(object sender, EventArgs e) { if (receivedJetski == null) { Jetski jetski = new Jetski(); jetski.TypeName = TypeNames.jetski; EditJetski(jetski); FMain.AddVehicle(jetski); } else { EditJetski(receivedJetski); } Close(); }
private void ButSave_Click(object sender, EventArgs e) { if (receivedTruck == null) { Truck truck = new Truck(); truck.TypeName = TypeNames.truck; EditTruck(truck); FMain.AddVehicle(truck); } else { EditTruck(receivedTruck); } Close(); }