diff options
author | Dirk Hohndel <dirk@hohndel.org> | 2019-10-19 22:10:51 -0400 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2019-10-20 16:08:55 -0400 |
commit | 09c7115e2192c30ee86007b1dcdec04134813751 (patch) | |
tree | e411bda69c3caf169c5b51c61795afbf80c0d150 /core | |
parent | 5a10cd42f7f0d5eef6a220046c4ed2671baea6c4 (diff) | |
download | subsurface-09c7115e2192c30ee86007b1dcdec04134813751.tar.gz |
Core: make helper functions global
We'll use them from the model in order to avoid creating this many
DiveObjectHelpers when showing a dive.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'core')
-rw-r--r-- | core/subsurface-qt/DiveObjectHelper.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/core/subsurface-qt/DiveObjectHelper.cpp b/core/subsurface-qt/DiveObjectHelper.cpp index 85138c0c0..f13319084 100644 --- a/core/subsurface-qt/DiveObjectHelper.cpp +++ b/core/subsurface-qt/DiveObjectHelper.cpp @@ -63,7 +63,7 @@ static QString getPressures(const struct dive *dive, int i, enum returnPressureS return fmt; } -static QString format_gps_decimal(const dive *d) +QString format_gps_decimal(const dive *d) { bool savep = prefs.coordinates_traditional; @@ -73,7 +73,7 @@ static QString format_gps_decimal(const dive *d) return val; } -static QString formatNotes(const dive *d) +QString formatNotes(const dive *d) { QString tmp = d->notes ? QString::fromUtf8(d->notes) : QString(); if (is_dc_planner(&d->dc)) { @@ -118,7 +118,7 @@ static QString formatGas(const dive *d) return gases; } -static QString formatSac(const dive *d) +QString formatSac(const dive *d) { if (!d->sac) return QString(); @@ -152,7 +152,7 @@ static QStringList formatWeights(const dive *d) return weights; } -static QStringList formatCylinders(const dive *d) +QStringList formatCylinders(const dive *d) { QStringList cylinders; for (int i = 0; i < MAX_CYLINDERS; i++) { @@ -175,7 +175,7 @@ static QVector<CylinderObjectHelper> makeCylinderObjects(const dive *d) return res; } -static QStringList formatGetCylinder(const dive *d) +QStringList formatGetCylinder(const dive *d) { QStringList getCylinder; for (int i = 0; i < MAX_CYLINDERS; i++) { @@ -185,7 +185,7 @@ static QStringList formatGetCylinder(const dive *d) return getCylinder; } -static QStringList getStartPressure(const dive *d) +QStringList getStartPressure(const dive *d) { QStringList startPressure; for (int i = 0; i < MAX_CYLINDERS; i++) { @@ -195,7 +195,7 @@ static QStringList getStartPressure(const dive *d) return startPressure; } -static QStringList getEndPressure(const dive *d) +QStringList getEndPressure(const dive *d) { QStringList endPressure; for (int i = 0; i < MAX_CYLINDERS; i++) { @@ -205,7 +205,7 @@ static QStringList getEndPressure(const dive *d) return endPressure; } -static QStringList getFirstGas(const dive *d) +QStringList getFirstGas(const dive *d) { QStringList gas; for (int i = 0; i < MAX_CYLINDERS; i++) { |