core: move divesite_has_gps_information() to struct dive_site

Seems logical in a C++ code base.

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
Berthold Stoeger 2024-06-30 17:38:36 +02:00 committed by bstoeger
parent c812dd140b
commit 0aa4efb3d9
14 changed files with 20 additions and 21 deletions

View file

@ -181,7 +181,7 @@ static void parse_dive_gps(char *line, struct git_parser_state *state)
ds = state->log->sites.create(std::string(), location);
ds->add_dive(state->active_dive.get());
} else {
if (dive_site_has_gps_location(ds) && ds->location != location) {
if (ds->has_gps_location() && ds->location != location) {
std::string coords = printGPSCoordsC(&location);
// we have a dive site that already has GPS coordinates
// note 1: there will be much less copying once the core