aboutsummaryrefslogtreecommitdiffstats
path: root/desktop-widgets/diveshareexportdialog.ui
diff options
context:
space:
mode:
authorGravatar Berthold Stoeger <bstoeger@mail.tuwien.ac.at>2018-12-09 13:01:10 +0100
committerGravatar Dirk Hohndel <dirk@hohndel.org>2018-12-14 00:29:31 +0800
commitc64c9c923b1f2a4758f3ff639c28790f99c9ce84 (patch)
tree496b41c40c90cef05eb392bd595977846840d8d5 /desktop-widgets/diveshareexportdialog.ui
parentdfd7f98129c2b9cb862ac414a84c5d82ffa407d0 (diff)
downloadsubsurface-c64c9c923b1f2a4758f3ff639c28790f99c9ce84.tar.gz
Cleanup: detangle unregister_dive() and delete_single_dive()
These two functions were called in different contexts: - unregister_dive(): from the undo-commands to remove the dive from the global dive table, but not delete it. The dive was already removed from its trip. - delete_single_dive(): from non-undo code. Most of it not in use and removed in a sibling-commit. Here, the dive is supposed to be removed from its trip and a new selection is calculated. delete_single_dive() calls unregister_dive(), which removes the dive from its trip. Move remove_dive_from_trip() from the former to the latter and make both functions independent. Instead of deleting the dive explicitly in delete_single_dive(), call the delete_dive_from_table() function. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'desktop-widgets/diveshareexportdialog.ui')
0 files changed, 0 insertions, 0 deletions