forked from openlp/openlp
Add Yes / No to Error Message
This commit is contained in:
parent
afaf10f986
commit
dce9a73153
@ -133,10 +133,13 @@ class OpenLP(QtGui.QApplication):
|
||||
def isAlreadyRunning(self):
|
||||
self.sharedMemory = QtCore.QSharedMemory('OpenLP')
|
||||
if self.sharedMemory.attach():
|
||||
QtGui.QMessageBox.critical(None,
|
||||
status = QtGui.QMessageBox.critical(None,
|
||||
UiStrings.Error, UiStrings.OpenLPStart,
|
||||
QtGui.QMessageBox.StandardButtons(QtGui.QMessageBox.Ok))
|
||||
return True
|
||||
QtGui.QMessageBox.StandardButtons(
|
||||
QtGui.QMessageBox.Yes | QtGui.QMessageBox.No))
|
||||
if status == QtGui.QMessageBox.No:
|
||||
return True
|
||||
return False
|
||||
else:
|
||||
self.sharedMemory.create(1)
|
||||
return False
|
||||
|
@ -76,7 +76,8 @@ class UiStrings(object):
|
||||
NISp = translate('OpenLP.Ui', 'No Items Selected', 'Plural')
|
||||
OLPV1 = translate('OpenLP.Ui', 'openlp.org 1.x')
|
||||
OLPV2 = translate('OpenLP.Ui', 'OpenLP 2.0')
|
||||
OpenLPStart = translate('OpenLP.Ui', 'OpenLP is already running')
|
||||
OpenLPStart = translate('OpenLP.Ui', 'OpenLP is already running. Do you '
|
||||
'wish continue.')
|
||||
OpenService = translate('OpenLP.Ui', 'Open Service')
|
||||
Preview = translate('OpenLP.Ui', 'Preview')
|
||||
PreviewPanel = translate('OpenLP.Ui', 'Preview Panel')
|
||||
|
Loading…
Reference in New Issue
Block a user