summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Tomaz Canabrava <tomaz.canabrava@intel.com>2016-01-11 15:05:07 -0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2016-01-11 15:46:11 -0800
commit820cd0c28d9db6a6bc00a4bd8310bb669bec4db4 (patch)
treed6595353e8c30dce03fae78d17000e0c62923e2b
parent438b5df089edb3f8a90a6fa1bfdb5abba9847749 (diff)
downloadsubsurface-820cd0c28d9db6a6bc00a4bd8310bb669bec4db4.tar.gz
Simplify: remove uneeded variable, rating.
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.cpp3
-rw-r--r--subsurface-core/subsurface-qt/DiveObjectHelper.h1
2 files changed, 1 insertions, 3 deletions
diff --git a/subsurface-core/subsurface-qt/DiveObjectHelper.cpp b/subsurface-core/subsurface-qt/DiveObjectHelper.cpp
index c7e111d3b..621918ef0 100644
--- a/subsurface-core/subsurface-qt/DiveObjectHelper.cpp
+++ b/subsurface-core/subsurface-qt/DiveObjectHelper.cpp
@@ -34,7 +34,6 @@ static QString getFormattedCylinder(struct dive *dive, unsigned int idx)
}
DiveObjectHelper::DiveObjectHelper(struct dive *d) :
- m_rating(d->rating),
m_timestamp(d->when),
m_location(get_dive_location(d) ? QString::fromUtf8(get_dive_location(d)) : EMPTY_DIVE_STRING),
m_duration(get_dive_duration_string(d->duration.seconds, QObject::tr("h:"), QObject::tr("min"))),
@@ -255,5 +254,5 @@ QString DiveObjectHelper::otu() const
int DiveObjectHelper::rating() const
{
- return m_rating;
+ return m_dive->rating;
}
diff --git a/subsurface-core/subsurface-qt/DiveObjectHelper.h b/subsurface-core/subsurface-qt/DiveObjectHelper.h
index f1c1a19d5..19d88e038 100644
--- a/subsurface-core/subsurface-qt/DiveObjectHelper.h
+++ b/subsurface-core/subsurface-qt/DiveObjectHelper.h
@@ -62,7 +62,6 @@ public:
QString otu() const;
private:
- int m_rating;
QString m_date;
timestamp_t m_timestamp;
QString m_time;