core: move constructLocationTags from divesite.cpp to taxonomy.cpp

After all it doesn't access any dive_site structure.

Moreover, rename it, since we use mostly snake_case in core.

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
Berthold Stoeger 2024-05-11 18:23:40 +02:00 committed by bstoeger
parent 7d7766be9a
commit 4ac2486a23
6 changed files with 55 additions and 55 deletions

View file

@ -178,7 +178,7 @@ void TabDiveNotes::updateDiveSite(struct dive *d)
struct dive_site *ds = d->dive_site;
ui.location->setCurrentDiveSite(d);
if (ds) {
ui.locationTags->setText(QString::fromStdString(constructLocationTags(ds->taxonomy, true)));
ui.locationTags->setText(QString::fromStdString(taxonomy_get_location_tags(ds->taxonomy, true)));
if (ui.locationTags->text().isEmpty() && has_location(&ds->location))
ui.locationTags->setText(printGPSCoords(&ds->location));