From 8d791a51f43638c3931733b60d6d1aec1cec3834 Mon Sep 17 00:00:00 2001 From: Samuel Mehrbrodt Date: Wed, 26 Aug 2015 10:37:16 +0200 Subject: [PATCH] Better wording for close dialog --- openlp/core/ui/mainwindow.py | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/openlp/core/ui/mainwindow.py b/openlp/core/ui/mainwindow.py index 6ac62c32a..569ed2133 100644 --- a/openlp/core/ui/mainwindow.py +++ b/openlp/core/ui/mainwindow.py @@ -1082,13 +1082,14 @@ class MainWindow(QtGui.QMainWindow, Ui_MainWindow, RegistryProperties): event.ignore() else: if Settings().value('advanced/enable exit confirmation'): - ret = QtGui.QMessageBox.question(self, translate('OpenLP.MainWindow', 'Close OpenLP'), + msg_box = QtGui.QMessageBox(QtGui.QMessageBox.Question, translate('OpenLP.MainWindow', 'Close OpenLP'), translate('OpenLP.MainWindow', 'Are you sure you want to close ' 'OpenLP?'), - QtGui.QMessageBox.StandardButtons(QtGui.QMessageBox.Yes | - QtGui.QMessageBox.No), - QtGui.QMessageBox.Yes) - if ret == QtGui.QMessageBox.Yes: + QtGui.QMessageBox.StandardButtons(QtGui.QMessageBox.Close | + QtGui.QMessageBox.Cancel), self) + msg_box.setButtonText(QtGui.QMessageBox.Close, translate('OpenLP.MainWindow', 'Close OpenLP')) + msg_box.setDefaultButton(QtGui.QMessageBox.Close) + if msg_box.exec() == QtGui.QMessageBox.Close: self.clean_up() event.accept() else: