core: convert taxonomy.c to C++

Since the taxonomy is now a real C++ struct with constructor
and destructor, dive_site has to be converted to C++ as well.

A bit hairy for now, but will ultimately be distinctly simpler.

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
Berthold Stoeger 2024-05-04 13:39:04 +02:00 committed by bstoeger
parent 3c1401785b
commit 3f8b4604be
39 changed files with 259 additions and 336 deletions

View file

@ -24,7 +24,7 @@ struct DiveToAdd {
struct DivesAndTripsToAdd {
std::vector<DiveToAdd> dives;
std::vector<OwningTripPtr> trips;
std::vector<OwningDiveSitePtr> sites;
std::vector<std::unique_ptr<dive_site>> sites;
};
// Dives and sites that have to be removed for a command
@ -111,7 +111,7 @@ private:
struct device_table devicesToAddAndRemove;
// For redo
std::vector<OwningDiveSitePtr> sitesToAdd;
std::vector<std::unique_ptr<dive_site>> sitesToAdd;
std::vector<std::pair<std::string,FilterData>>
filterPresetsToAdd;