forked from openlp/openlp
removed information_message_box
This commit is contained in:
parent
b12a37b986
commit
1a645acc06
12
openlp.pyw
12
openlp.pyw
@ -35,7 +35,6 @@ from subprocess import Popen, PIPE
|
|||||||
from PyQt4 import QtCore, QtGui
|
from PyQt4 import QtCore, QtGui
|
||||||
|
|
||||||
from openlp.core.lib import Receiver, translate, check_directory_exists
|
from openlp.core.lib import Receiver, translate, check_directory_exists
|
||||||
from openlp.core.lib.ui import information_message_box
|
|
||||||
from openlp.core.resources import qInitResources
|
from openlp.core.resources import qInitResources
|
||||||
from openlp.core.ui.mainwindow import MainWindow
|
from openlp.core.ui.mainwindow import MainWindow
|
||||||
from openlp.core.ui.exceptionform import ExceptionForm
|
from openlp.core.ui.exceptionform import ExceptionForm
|
||||||
@ -233,10 +232,13 @@ class OpenLP(QtGui.QApplication):
|
|||||||
"""
|
"""
|
||||||
Called when the user changes the monitor set up.
|
Called when the user changes the monitor set up.
|
||||||
"""
|
"""
|
||||||
information_message_box(
|
data = {
|
||||||
message=translate('OpenLP','You have changed the monitor set up. '
|
u'title': translate('OpenLP.Ui', 'Information'),
|
||||||
'You have to restart OpenLP in order to change the live display '
|
u'message': translate('OpenLP','The monitor set up has changed. You'
|
||||||
'monitor.'))
|
' have to restart OpenLP in order to change the live display'
|
||||||
|
' monitor.')
|
||||||
|
}
|
||||||
|
Receiver.send_message(u'openlp_information_message', data)
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
"""
|
"""
|
||||||
|
@ -58,7 +58,6 @@ class UiStrings(object):
|
|||||||
'Abbreviated font pointsize unit')
|
'Abbreviated font pointsize unit')
|
||||||
Image = translate('OpenLP.Ui', 'Image')
|
Image = translate('OpenLP.Ui', 'Image')
|
||||||
Import = translate('OpenLP.Ui', 'Import')
|
Import = translate('OpenLP.Ui', 'Import')
|
||||||
Information = translate('OpenLP.Ui', 'Information')
|
|
||||||
LengthTime = unicode(translate('OpenLP.Ui', 'Length %s'))
|
LengthTime = unicode(translate('OpenLP.Ui', 'Length %s'))
|
||||||
Live = translate('OpenLP.Ui', 'Live')
|
Live = translate('OpenLP.Ui', 'Live')
|
||||||
LiveBGError = translate('OpenLP.Ui', 'Live Background Error')
|
LiveBGError = translate('OpenLP.Ui', 'Live Background Error')
|
||||||
@ -174,32 +173,6 @@ def critical_error_message_box(title=None, message=None, parent=None,
|
|||||||
data[u'title'] = title if title else UiStrings.Error
|
data[u'title'] = title if title else UiStrings.Error
|
||||||
return Receiver.send_message(u'openlp_error_message', data)
|
return Receiver.send_message(u'openlp_error_message', data)
|
||||||
|
|
||||||
def information_message_box(title=None, message=None, parent=None,
|
|
||||||
question=False):
|
|
||||||
"""
|
|
||||||
Provides a standard information message box for notes that OpenLP displays
|
|
||||||
to users.
|
|
||||||
|
|
||||||
``title``
|
|
||||||
The title for the message box.
|
|
||||||
|
|
||||||
``message``
|
|
||||||
The message to display to the user.
|
|
||||||
|
|
||||||
``parent``
|
|
||||||
The parent UI element to attach the dialog to.
|
|
||||||
|
|
||||||
``question``
|
|
||||||
Should this message box question the user.
|
|
||||||
"""
|
|
||||||
if question:
|
|
||||||
return QtGui.QMessageBox.critical(parent, UiStrings.Information,
|
|
||||||
message, QtGui.QMessageBox.StandardButtons(
|
|
||||||
QtGui.QMessageBox.Yes | QtGui.QMessageBox.No))
|
|
||||||
data = {u'message': message}
|
|
||||||
data[u'title'] = title if title else UiStrings.Information
|
|
||||||
return Receiver.send_message(u'openlp_information_message', data)
|
|
||||||
|
|
||||||
def media_item_combo_box(parent, name):
|
def media_item_combo_box(parent, name):
|
||||||
"""
|
"""
|
||||||
Provide a standard combo box for media items.
|
Provide a standard combo box for media items.
|
||||||
|
Loading…
Reference in New Issue
Block a user