Add a MeanDepthItem that has 2 strings.

Dirk's implementation of the MeanDepth item was correct, but in order to
add the 2 strings to it ( one at the begin, one at the end ) I had to put
more stuff inside the ProfileWidget that's already packed with graphics
items.

So I created a new class MeanDepthItem that contains these 2 strings and
will get updated whenever the value changes.

I also fixed a math inconsistency where I changed RIGHT to LEFT.
(wich fixed a few text-placements, and broke others.)

Signed-off-by: Tomaz Canabrava <tcanabrava@kde.org>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Tomaz Canabrava 2014-01-22 15:08:19 -02:00 committed by Dirk Hohndel
parent f22428b345
commit 2e2a87e619
5 changed files with 47 additions and 6 deletions

View file

@ -16,6 +16,7 @@
#include "graphicsview-common.h"
#include "divelineitem.h"
class MeanDepthLine;
class DiveReportedCeiling;
class DiveTextItem;
class TemperatureAxis;
@ -83,7 +84,7 @@ private:
DiveTemperatureItem *temperatureItem;
DiveCartesianAxis *cylinderPressureAxis;
DiveGasPressureItem *gasPressureItem;
DiveLineItem *meanDepth;
MeanDepthLine *meanDepth;
QList<DiveEventItem*> eventItems;
DiveTextItem *diveComputerText;
DiveCalculatedCeiling *diveCeiling;