diff options
author | Berthold Stoeger <bstoeger@mail.tuwien.ac.at> | 2020-10-21 23:34:15 +0200 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2020-10-25 13:59:04 -0700 |
commit | 3358bff4322714b59c6f54e67a0db980f215a29d (patch) | |
tree | a4c89ede782fbe399f4c67c9fd65bfa31f7a4502 /core/divelist.c | |
parent | c263487e7ce7c7b22e516650eb857c646728c34a (diff) | |
download | subsurface-3358bff4322714b59c6f54e67a0db980f215a29d.tar.gz |
cleanup: move mark_divelist_changed() to qmlmanager.cpp
Desktop does not use mark_divelist_changed() anymore - all is done
via the undo machinery. Therefore move this function (and its
counterpart unsaved_changes()) to qmlmanager.cpp.
Ultimately, it probably should be removed from there as well, but
currently I don't dare to touch all the cloud-logic!
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'core/divelist.c')
-rw-r--r-- | core/divelist.c | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/core/divelist.c b/core/divelist.c index 2dd4e3e81..3599ec498 100644 --- a/core/divelist.c +++ b/core/divelist.c @@ -17,10 +17,6 @@ #include "table.h" #include "trip.h" -/* This flag is set to true by operations that are not implemented in the - * undo system. It is therefore only cleared on save and load. */ -static bool dive_list_changed = false; - bool autogroup = false; void set_autogroup(bool value) @@ -803,19 +799,6 @@ bool filter_dive(struct dive *d, bool shown) return changed; } -void mark_divelist_changed(bool changed) -{ - if (dive_list_changed == changed) - return; - dive_list_changed = changed; - updateWindowTitle(); -} - -int unsaved_changes() -{ - return dive_list_changed; -} - void process_loaded_dives() { int i; @@ -1058,7 +1041,6 @@ void add_imported_dives(struct dive_table *import_table, struct trip_table *impo /* We might have deleted the old selected dive. * Choose the newest dive as selected (if any) */ current_dive = dive_table.nr > 0 ? dive_table.dives[dive_table.nr - 1] : NULL; - mark_divelist_changed(true); free_device_table(devices_to_add); |