Added the code for the PHE gas pressure.

Using the PartialPressureGasItem the addition of a new partial plot
is very easy.

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-23 17:59:14 -02:00 committed by Dirk Hohndel
parent caa45a1539
commit 1cae362c16
4 changed files with 14 additions and 1 deletions

View file

@ -180,6 +180,16 @@ ProfileWidget2::ProfileWidget2(QWidget *parent) :
pn2GasItem->setThreshouldSettingsKey("pn2threshold");
scene()->addItem(pn2GasItem);
pheGasItem = new PartialPressureGasItem();
pheGasItem->setHorizontalAxis(timeAxis);
pheGasItem->setVerticalAxis(gasYAxis);
pheGasItem->setModel(dataModel);
pheGasItem->setVerticalDataColumn(DivePlotDataModel::PHE);
pheGasItem->setHorizontalDataColumn(DivePlotDataModel::TIME);
pheGasItem->setZValue(0);
pheGasItem->setThreshouldSettingsKey("phethreshold");
scene()->addItem(pheGasItem);
background->setFlag(QGraphicsItem::ItemIgnoresTransformations);
//enum State{ EMPTY, PROFILE, EDIT, ADD, PLAN, INVALID };