diff options
author | Dirk Hohndel <dirk@hohndel.org> | 2014-11-06 11:24:38 -0800 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2014-11-07 13:00:58 -0800 |
commit | 45251ec7248a0300506af043b0a5c448051b2072 (patch) | |
tree | 5ade6357ec26c2412788844d48db76e9fdd3dcd7 /qt-ui/maintab.cpp | |
parent | 4ccddf95d7660b9c2c91da1d72f08bd45988c83e (diff) | |
download | subsurface-45251ec7248a0300506af043b0a5c448051b2072.tar.gz |
Show extra data in separate tab on MainTab
This way any extra data probided by the dive computer is visible to the
user (without other processing). This data cannot be edited by the user as
it reflects the information given by the dive computer.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui/maintab.cpp')
-rw-r--r-- | qt-ui/maintab.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/qt-ui/maintab.cpp b/qt-ui/maintab.cpp index 545632f75..ab712aeca 100644 --- a/qt-ui/maintab.cpp +++ b/qt-ui/maintab.cpp @@ -32,6 +32,7 @@ MainTab::MainTab(QWidget *parent) : QTabWidget(parent), weightModel(new WeightModel(this)), cylindersModel(CylindersModel::instance()), + extraDataModel(new ExtraDataModel(this)), editMode(NONE), divePictureModel(DivePictureModel::instance()), currentTrip(0), @@ -47,6 +48,7 @@ MainTab::MainTab(QWidget *parent) : QTabWidget(parent), ui.weights->setModel(weightModel); ui.photosView->setModel(divePictureModel); connect(ui.photosView, SIGNAL(photoDoubleClicked(QString)), this, SLOT(photoDoubleClicked(QString))); + ui.extraData->setModel(extraDataModel); closeMessage(); QAction *action = new QAction(tr("Save"), this); @@ -473,6 +475,7 @@ void MainTab::updateDiveInfo(bool clear) ui.equipmentTab->setEnabled(true); cylindersModel->updateDive(); weightModel->updateDive(); + extraDataModel->updateDive(); taglist_get_tagstring(displayed_dive.tag_list, buf, 1024); ui.tagWidget->setText(QString(buf)); } @@ -899,6 +902,7 @@ void MainTab::rejectChanges() weightModel->changed = false; cylindersModel->updateDive(); weightModel->updateDive(); + extraDataModel->updateDive(); } #undef EDIT_TEXT2 |