From ab3e4b82161c99b88bbbb2515a0ef26a57a53b8e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ole-Andr=C3=A9=20Rodlie?= Date: Wed, 2 Oct 2024 21:10:26 +0200 Subject: [PATCH] Confirm revert action Make user confirm revert action. --- src/app/GUI/mainwindow.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/app/GUI/mainwindow.cpp b/src/app/GUI/mainwindow.cpp index 0f43460e1..38879dc3f 100644 --- a/src/app/GUI/mainwindow.cpp +++ b/src/app/GUI/mainwindow.cpp @@ -2029,6 +2029,11 @@ void MainWindow::importImageSequence() void MainWindow::revert() { + const int ask = QMessageBox::question(this, + tr("Confirm revert"), + tr("Are you sure you want to revert current project?" + "

Any changes will be lost.

")); + if (ask == QMessageBox::No) { return; } const QString path = mDocument.fEvFile; openFile(path); }