diff options
-rw-r--r-- | desktop-widgets/diveplanner.cpp | 5 | ||||
-rw-r--r-- | desktop-widgets/maintab.cpp | 2 |
2 files changed, 3 insertions, 4 deletions
diff --git a/desktop-widgets/diveplanner.cpp b/desktop-widgets/diveplanner.cpp index fddc5bb19..375f23208 100644 --- a/desktop-widgets/diveplanner.cpp +++ b/desktop-widgets/diveplanner.cpp @@ -23,7 +23,6 @@ #define UNIT_FACTOR ((prefs.units.length == units::METERS) ? 1000.0 / 60.0 : feet_to_mm(1.0) / 60.0) static DivePlannerPointsModel* plannerModel = DivePlannerPointsModel::instance(); -static CylindersModel* cylinderModel = CylindersModel::instance(); DiveHandler::DiveHandler() : QGraphicsEllipseItem() { @@ -354,8 +353,8 @@ PlannerSettingsWidget::PlannerSettingsWidget(QWidget *parent, Qt::WindowFlags f) connect(ui.min_switch_duration, SIGNAL(valueChanged(int)), plannerModel, SLOT(setMinSwitchDuration(int))); connect(ui.rebreathermode, SIGNAL(currentIndexChanged(int)), plannerModel, SLOT(setRebreatherMode(int))); - connect(ui.bottompo2, SIGNAL(valueChanged(double)), cylinderModel, SLOT(updateBestMixes())); - connect(ui.bestmixEND, SIGNAL(valueChanged(int)), cylinderModel, SLOT(updateBestMixes())); + connect(ui.bottompo2, SIGNAL(valueChanged(double)), CylindersModel::instance(), SLOT(updateBestMixes())); + connect(ui.bestmixEND, SIGNAL(valueChanged(int)), CylindersModel::instance(), SLOT(updateBestMixes())); connect(modeMapper, SIGNAL(mapped(int)), this, SLOT(disableDecoElements(int))); connect(ui.ascRate75, SIGNAL(valueChanged(int)), this, SLOT(setAscRate75(int))); diff --git a/desktop-widgets/maintab.cpp b/desktop-widgets/maintab.cpp index f6e5b7dc6..4766bf050 100644 --- a/desktop-widgets/maintab.cpp +++ b/desktop-widgets/maintab.cpp @@ -34,7 +34,7 @@ MainTab::MainTab(QWidget *parent) : QTabWidget(parent), weightModel(new WeightModel(this)), - cylindersModel(CylindersModel::instance()), + cylindersModel(new CylindersModel(this)), extraDataModel(new ExtraDataModel(this)), editMode(NONE), divePictureModel(DivePictureModel::instance()), |