undo: remove TabDiveWidget::acceptChanges and rejectChanges

Since cylinders are now edited using the undo system, these
functions are not needed anymore.

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
Berthold Stoeger 2020-02-27 18:40:32 +01:00
parent 04ce908e8e
commit 0732bb2302
3 changed files with 0 additions and 91 deletions

View file

@ -534,10 +534,6 @@ void MainTab::acceptChanges()
ui.dateEdit->setEnabled(true);
hideMessage();
// TODO: This is a temporary hack until the equipment tab is included in the undo system:
// The equipment tab is hardcoded at the first place of the "extra widgets".
((TabDiveEquipment *)extraWidgets[0])->acceptChanges();
if (lastMode == MANUALLY_ADDED_DIVE) {
MainWindow::instance()->showProfile();
DivePlannerPointsModel::instance()->setPlanMode(DivePlannerPointsModel::NOTHING);
@ -606,10 +602,6 @@ void MainTab::rejectChanges()
clear_dive(&displayed_dive);
updateDiveInfo();
// TODO: This is a temporary hack until the equipment tab is included in the undo system:
// The equipment tab is hardcoded at the first place of the "extra widgets".
((TabDiveEquipment *)extraWidgets[0])->rejectChanges();
// the user could have edited the location and then canceled the edit
// let's get the correct location back in view
MapWidget::instance()->centerOnDiveSite(current_dive ? current_dive->dive_site : nullptr);