summaryrefslogtreecommitdiffstats
path: root/qt-ui/mainwindow.cpp
diff options
context:
space:
mode:
authorGravatar Tomaz Canabrava <tomaz.canabrava@intel.com>2015-08-25 21:08:05 -0300
committerGravatar Dirk Hohndel <dirk@hohndel.org>2015-08-25 18:00:26 -0700
commitb8a09ca5208bca204120620e5bbeae75e6fe76a9 (patch)
tree1efdeac1250009d14e554df9ccea13ee15cc7ee9 /qt-ui/mainwindow.cpp
parentfc6d819616b69f7c69dc8743bc25aa8ad51708a4 (diff)
downloadsubsurface-b8a09ca5208bca204120620e5bbeae75e6fe76a9.tar.gz
Keep the dive list disabled if editing a dive
When, in a dive edit mode user entered a dive site and went to dive site edit mode then finished the ds edit, the app would lose the disabled property of the dive list, making it possible to select a new dive when we where editing another one, complete mess. Signed-off-by: Tomaz Canabrava <tomaz.canabrava@intel.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui/mainwindow.cpp')
-rw-r--r--qt-ui/mainwindow.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/qt-ui/mainwindow.cpp b/qt-ui/mainwindow.cpp
index 99be8422c..23c36adaa 100644
--- a/qt-ui/mainwindow.cpp
+++ b/qt-ui/mainwindow.cpp
@@ -258,6 +258,9 @@ PlannerSettingsWidget *MainWindow::divePlannerSettingsWidget() {
void MainWindow::setDefaultState() {
setApplicationState("Default");
+ if (information()->getEditMode() != MainTab::NONE) {
+ ui.bottomLeft->currentWidget()->setEnabled(false);
+ }
}
void MainWindow::setLoadedWithFiles(bool f)