diff options
Diffstat (limited to 'qt-ui/mainwindow.cpp')
-rw-r--r-- | qt-ui/mainwindow.cpp | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/qt-ui/mainwindow.cpp b/qt-ui/mainwindow.cpp index 687fc778d..29212564b 100644 --- a/qt-ui/mainwindow.cpp +++ b/qt-ui/mainwindow.cpp @@ -114,6 +114,8 @@ MainWindow::MainWindow() : QMainWindow(), #ifdef NO_PRINTING ui.menuFile->removeAction(ui.actionPrint); #endif + memset(©PasteDive, 0, sizeof(copyPasteDive)); + memset(&what, 0, sizeof(what)); } MainWindow::~MainWindow() @@ -1300,3 +1302,16 @@ void MainWindow::setEnabledToolbar(bool arg1) Q_FOREACH(QToolButton *b, toolBar) b->setEnabled(arg1); } + +void MainWindow::on_copy_triggered() +{ + // open dialog to select what gets copied + // copy the displayed dive + DiveComponentSelection dialog(this, ©PasteDive, &what); + dialog.exec(); +} + +void MainWindow::on_paste_triggered() +{ + // take the data in our copyPasteDive and apply it to selected dives +} |