diff options
author | Tomaz Canabrava <tomaz.canabrava@intel.com> | 2016-01-11 15:36:12 -0200 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2016-01-11 15:46:11 -0800 |
commit | 0bb661c3e1dd0a30e6815f758c7e49e40604f899 (patch) | |
tree | a3226ff9a713b25f773f8d348db59bdcb9ea76a0 | |
parent | ae222f147cd1e32c4bf4802b303c63c6be42e796 (diff) | |
download | subsurface-0bb661c3e1dd0a30e6815f758c7e49e40604f899.tar.gz |
Simplify: removed duration and depth variables
Signed-off-by: Tomaz Canabrava <tomaz.canabrava@intel.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
-rw-r--r-- | subsurface-core/subsurface-qt/DiveObjectHelper.cpp | 6 | ||||
-rw-r--r-- | subsurface-core/subsurface-qt/DiveObjectHelper.h | 2 |
2 files changed, 2 insertions, 6 deletions
diff --git a/subsurface-core/subsurface-qt/DiveObjectHelper.cpp b/subsurface-core/subsurface-qt/DiveObjectHelper.cpp index e50dc91aa..5e441d892 100644 --- a/subsurface-core/subsurface-qt/DiveObjectHelper.cpp +++ b/subsurface-core/subsurface-qt/DiveObjectHelper.cpp @@ -34,8 +34,6 @@ static QString getFormattedCylinder(struct dive *dive, unsigned int idx) } DiveObjectHelper::DiveObjectHelper(struct dive *d) : - m_duration(get_dive_duration_string(d->duration.seconds, QObject::tr("h:"), QObject::tr("min"))), - m_depth(get_depth_string(d->dc.maxdepth.mm, true, true)), m_divemaster(d->divemaster ? d->divemaster : EMPTY_DIVE_STRING), m_buddy(d->buddy ? d->buddy : EMPTY_DIVE_STRING), m_airTemp(get_temperature_string(d->airtemp, true)), @@ -158,12 +156,12 @@ QString DiveObjectHelper::gps() const } QString DiveObjectHelper::duration() const { - return m_duration; + return get_dive_duration_string(m_dive->duration.seconds, QObject::tr("h:"), QObject::tr("min")); } QString DiveObjectHelper::depth() const { - return m_depth; + return get_depth_string(m_dive->dc.maxdepth.mm, true, true); } QString DiveObjectHelper::divemaster() const diff --git a/subsurface-core/subsurface-qt/DiveObjectHelper.h b/subsurface-core/subsurface-qt/DiveObjectHelper.h index f135466c4..4a78fd779 100644 --- a/subsurface-core/subsurface-qt/DiveObjectHelper.h +++ b/subsurface-core/subsurface-qt/DiveObjectHelper.h @@ -65,8 +65,6 @@ private: QString m_date; QString m_time; QString m_gps; - QString m_duration; - QString m_depth; QString m_divemaster; QString m_buddy; QString m_airTemp; |