summaryrefslogtreecommitdiffstats
path: root/core/subsurface-qt/DiveObjectHelper.cpp
diff options
context:
space:
mode:
authorGravatar Berthold Stoeger <bstoeger@mail.tuwien.ac.at>2018-10-25 20:46:12 +0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2018-10-29 00:09:31 +0000
commit75b5d61522f3721adb1761141ce1aeb79c3761c1 (patch)
treeb9cb8f62df1d7fa2210b4b2c34ef8afb879bc5c1 /core/subsurface-qt/DiveObjectHelper.cpp
parent872d56de0122036e1b9d37348d758b40dcd142d9 (diff)
downloadsubsurface-75b5d61522f3721adb1761141ce1aeb79c3761c1.tar.gz
Dive site: replace UUID by pointer in mobile code
Replace UUIDs by pointers to dive-site in mobile code. In both cases, the value is transported via a QVariant. The function getCoordinatesForUUID(), which was only used from mobile, can be replaced by a getCoordinatesFor() function taking a variant supposed to contain a dive-site pointer. Likewise, the variant of the centerOnDiveSite function is now supposed to wrap a pointer-to-divesite. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'core/subsurface-qt/DiveObjectHelper.cpp')
-rw-r--r--core/subsurface-qt/DiveObjectHelper.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/core/subsurface-qt/DiveObjectHelper.cpp b/core/subsurface-qt/DiveObjectHelper.cpp
index d4b8e32cb..c605d01c8 100644
--- a/core/subsurface-qt/DiveObjectHelper.cpp
+++ b/core/subsurface-qt/DiveObjectHelper.cpp
@@ -127,9 +127,9 @@ QString DiveObjectHelper::gps_decimal() const
return val;
}
-QVariant DiveObjectHelper::dive_site_uuid() const
+QVariant DiveObjectHelper::dive_site() const
{
- return QVariant::fromValue(m_dive->dive_site_uuid);
+ return QVariant::fromValue((void *)get_dive_site_by_uuid(m_dive->dive_site_uuid));
}
QString DiveObjectHelper::duration() const