diff options
Diffstat (limited to 'gui')
-rw-r--r-- | gui/MainWindow.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/gui/MainWindow.cpp b/gui/MainWindow.cpp index dcb6d3b5..2e70a6a6 100644 --- a/gui/MainWindow.cpp +++ b/gui/MainWindow.cpp @@ -35,6 +35,7 @@ #include <QToolButton> #include <QWidgetAction> #include <QProgressDialog> +#include <QShortcut> #include "osutils.h" #include "userutils.h" @@ -116,6 +117,12 @@ MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent), ui(new Ui::MainWi // OSX magic. // setUnifiedTitleAndToolBarOnMac(true); + // Global shortcuts + { + auto q = new QShortcut(QKeySequence::Quit, this); + connect(q, &QShortcut::activated, qApp, &QCoreApplication::quit); + } + // The instance action toolbar customizations { // disabled until we have an instance selected |