core: move get_dive_location()/_country() to struct dive

Feels natural 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 20:55:34 +02:00 committed by bstoeger
parent f1f082d86a
commit 76d672210d
9 changed files with 18 additions and 21 deletions

View file

@ -1066,7 +1066,7 @@ bool QMLManager::checkLocation(DiveSiteChange &res, struct dive *d, QString loca
{
struct dive_site *ds = d->dive_site;
bool changed = false;
QString oldLocation = QString::fromStdString(get_dive_location(d));
QString oldLocation = QString::fromStdString(d->get_location());
if (oldLocation != location) {
ds = divelog.sites.get_by_name(location.toStdString());
if (!ds && !location.isEmpty()) {