summaryrefslogtreecommitdiffstats
path: root/qt-ui/mainwindow.cpp
diff options
context:
space:
mode:
authorGravatar Tomaz Canabrava <tcanabrava@kde.org>2013-06-27 14:48:03 -0300
committerGravatar Tomaz Canabrava <tcanabrava@kde.org>2013-06-27 14:48:03 -0300
commit1244438b017f71be466ace7df9cad9462287fd30 (patch)
treeaa7dcb8f0e52f54d01918f54e3ffd617eea4f9ea /qt-ui/mainwindow.cpp
parentde7506b44d03b4190d3a0205398d047e8303f75a (diff)
downloadsubsurface-1244438b017f71be466ace7df9cad9462287fd30.tar.gz
Moved the DivePlanner to the MainWindow.
Now, activating the dive planner will hide the profile and show the planner on the same place. we still need a way to 'cancel' or 'accept' the profile created. Signed-off-by: Tomaz Canabrava <tcanabrava@kde.org>
Diffstat (limited to 'qt-ui/mainwindow.cpp')
-rw-r--r--qt-ui/mainwindow.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/qt-ui/mainwindow.cpp b/qt-ui/mainwindow.cpp
index 3f16b50e5..66bebc6c7 100644
--- a/qt-ui/mainwindow.cpp
+++ b/qt-ui/mainwindow.cpp
@@ -223,11 +223,12 @@ void MainWindow::on_actionPrint_triggered()
void MainWindow::on_actionDivePlanner_triggered()
{
- DivePlanner *planner = DivePlanner::instance();
- if (planner->exec() == QDialog::Accepted){
- struct dive *d = planner->getDive();
- qDebug() << "Finish me.";
- }
+ ui->stackedWidget->setCurrentIndex(1);
+}
+
+void MainWindow::showProfile()
+{
+ ui->stackedWidget->setCurrentIndex(0);
}