mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
core: move clone_delete_divecomputer() to struct dive_table
Since this calls force_fixup_dive() it needs access to other dives in the dive_table. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
parent
576d3a3bc6
commit
79bf79ad7f
5 changed files with 25 additions and 26 deletions
|
|
@ -44,6 +44,7 @@ struct dive_table : public sorted_owning_table<dive, &comp_dives> {
|
|||
merge_result merge_dives(const struct dive &a_in, const struct dive &b_in, int offset, bool prefer_downloaded) const;
|
||||
std::unique_ptr<dive> try_to_merge(const struct dive &a, const struct dive &b, bool prefer_downloaded) const;
|
||||
bool has_dive(unsigned int deviceid, unsigned int diveid) const;
|
||||
std::unique_ptr<dive> clone_delete_divecomputer(const struct dive &d, int dc_number);
|
||||
private:
|
||||
int calculate_cns(struct dive &dive) const; // Note: writes into dive->cns
|
||||
std::array<std::unique_ptr<dive>, 2> split_dive_at(const struct dive &dive, int a, int b) const;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue