From f9906825e7822771f2f3741b1c696e71bf1c76ce Mon Sep 17 00:00:00 2001 From: isanae <14251494+isanae@users.noreply.github.com> Date: Mon, 3 Jun 2019 19:26:03 -0400 Subject: fixed exit menu item not working --- src/mainwindow.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'src/mainwindow.cpp') diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index f8c09b20..8eae1914 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -1069,12 +1069,12 @@ void MainWindow::showEvent(QShowEvent *event) void MainWindow::closeEvent(QCloseEvent* event) { - if (!exit()) { + if (!confirmExit()) { event->ignore(); } } -bool MainWindow::exit() +bool MainWindow::confirmExit() { m_closing = true; @@ -5518,7 +5518,9 @@ void MainWindow::on_actionUpdate_triggered() void MainWindow::on_actionExit_triggered() { - exit(); + if (confirmExit()) { + qApp->exit(); + } } void MainWindow::actionEndorseMO() -- cgit v1.3.1