aboutsummaryrefslogtreecommitdiffstats
path: root/profile-widget/profilewidget2.cpp
diff options
context:
space:
mode:
authorGravatar Berthold Stoeger <bstoeger@mail.tuwien.ac.at>2021-01-09 18:25:04 +0100
committerGravatar Dirk Hohndel <dirk@hohndel.org>2021-01-10 15:57:39 -0800
commit88c6ce988dfc1b5ad40eb9c425d705c8ac136570 (patch)
tree49a7642f6fa40b2a8a3e65e9d4ebc48dfc51e29a /profile-widget/profilewidget2.cpp
parent54e8fe5d9e588c3345ded27982edaf72654fc8d1 (diff)
downloadsubsurface-88c6ce988dfc1b5ad40eb9c425d705c8ac136570.tar.gz
profile: pass dive to RulerItem
Instead of accessing the global displayed_dive variable in RulerItem, pass the dive. This is a step in making the profile reentrant. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'profile-widget/profilewidget2.cpp')
-rw-r--r--profile-widget/profilewidget2.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/profile-widget/profilewidget2.cpp b/profile-widget/profilewidget2.cpp
index 49f99d20c..90638649d 100644
--- a/profile-widget/profilewidget2.cpp
+++ b/profile-widget/profilewidget2.cpp
@@ -691,7 +691,7 @@ void ProfileWidget2::plotDive(const struct dive *d, bool force, bool doClearPict
cylinderPressureAxis->setMinimum(plotInfo.minpressure);
cylinderPressureAxis->setMaximum(plotInfo.maxpressure);
#ifndef SUBSURFACE_MOBILE
- rulerItem->setPlotInfo(plotInfo);
+ rulerItem->setPlotInfo(&displayed_dive, plotInfo);
#endif
#ifdef SUBSURFACE_MOBILE