diff options
author | Julian T <julian@jtle.dk> | 2020-08-14 18:53:08 +0200 |
---|---|---|
committer | Julian T <julian@jtle.dk> | 2020-08-14 18:53:08 +0200 |
commit | 5ca04e5b2ec8eef88df6cbd4e3d09ac7dab55c0d (patch) | |
tree | 8333b03fc7f1d32be0fee1d9230899b6268cc8ae /app/mainwindow.cpp | |
parent | bef819f1e2a3d998d7ec7968dbb5fb691fc0d9f8 (diff) |
Added multithreading
Diffstat (limited to 'app/mainwindow.cpp')
-rw-r--r-- | app/mainwindow.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/app/mainwindow.cpp b/app/mainwindow.cpp index a365f38..3fcc9c5 100644 --- a/app/mainwindow.cpp +++ b/app/mainwindow.cpp @@ -18,9 +18,16 @@ MainWindow::MainWindow(Renderer r) saveAct->setStatusTip(tr("Save the rendered image")); connect(saveAct, &QAction::triggered, this, &MainWindow::saveimage); + auto stopAct = new QAction(tr("&Stop"), this); + stopAct->setStatusTip(tr("Stop and sync threads")); + QObject::connect(stopAct, &QAction::triggered, &m_render, &RenderCoordinator::stop); + fileMenu = menuBar()->addMenu(tr("&File")); fileMenu->addAction(saveAct); + fileMenu = menuBar()->addMenu(tr("&Render")); + fileMenu->addAction(stopAct); + helpMenu = menuBar()->addMenu(tr("&Help")); helpMenu->addAction(tr("About Qt"), qApp, &QApplication::aboutQt); |