summaryrefslogtreecommitdiffstats
path: root/profile-widget/diveprofileitem.cpp
diff options
context:
space:
mode:
authorGravatar Tomaz Canabrava <tomaz.canabrava@intel.com>2016-01-25 17:48:57 -0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2016-01-25 13:04:32 -0800
commit74333963330cc5f9d8a848487522e34a822c46de (patch)
tree7fdd709d13823735a0b44cd3ae29e6e24c933285 /profile-widget/diveprofileitem.cpp
parent49332bc635166103cc8491f1252d4d9c80b767cc (diff)
downloadsubsurface-74333963330cc5f9d8a848487522e34a822c46de.tar.gz
Fix Ceiling Graph
Signed-off-by: Tomaz Canabrava <tomaz.canabrava@intel.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'profile-widget/diveprofileitem.cpp')
-rw-r--r--profile-widget/diveprofileitem.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/profile-widget/diveprofileitem.cpp b/profile-widget/diveprofileitem.cpp
index 986ecae23..b090d2173 100644
--- a/profile-widget/diveprofileitem.cpp
+++ b/profile-widget/diveprofileitem.cpp
@@ -116,6 +116,14 @@ void AbstractProfilePolygonItem::modelDataChanged(const QModelIndex &topLeft, co
DiveProfileItem::DiveProfileItem() : show_reported_ceiling(0), reported_ceiling_in_red(0)
{
+ connect(SettingsObjectWrapper::instance()->techDetails, &TechnicalDetailsSettings::dcceilingChanged, this, &DiveProfileItem::settingsToggled);
+ connect(SettingsObjectWrapper::instance()->techDetails, &TechnicalDetailsSettings::redceilingChanged, this, &DiveProfileItem::settingsToggled);
+}
+
+void DiveProfileItem::settingsToggled(bool toggled)
+{
+ Q_UNUSED(toggled);
+ settingsChanged();
}
void DiveProfileItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget)