forked from openlp/openlp
pep8
This commit is contained in:
parent
645f92e7d4
commit
ec59abdc85
@ -566,7 +566,7 @@ class PJLink1(QTcpSocket):
|
|||||||
fill = {'Hours': int(data_dict[0]), 'On': False if data_dict[1] == '0' else True}
|
fill = {'Hours': int(data_dict[0]), 'On': False if data_dict[1] == '0' else True}
|
||||||
except ValueError:
|
except ValueError:
|
||||||
# In case of invalid entry
|
# In case of invalid entry
|
||||||
log.warn('(%s) process_lamp(): Invalid data "%s"' %( self.ip, data))
|
log.warn('(%s) process_lamp(): Invalid data "%s"' % (self.ip, data))
|
||||||
return
|
return
|
||||||
lamps.append(fill)
|
lamps.append(fill)
|
||||||
data_dict.pop(0) # Remove lamp hours
|
data_dict.pop(0) # Remove lamp hours
|
||||||
|
@ -46,6 +46,7 @@ from openlp.core.lib import build_icon
|
|||||||
from openlp.core.lib.projector.db import Projector
|
from openlp.core.lib.projector.db import Projector
|
||||||
from openlp.core.lib.projector.constants import PJLINK_PORT
|
from openlp.core.lib.projector.constants import PJLINK_PORT
|
||||||
|
|
||||||
|
|
||||||
class Ui_ProjectorEditForm(object):
|
class Ui_ProjectorEditForm(object):
|
||||||
"""
|
"""
|
||||||
The :class:`~opelp.core.lib.ui.projector.editform.Ui_ProjectorEdiForm` class defines
|
The :class:`~opelp.core.lib.ui.projector.editform.Ui_ProjectorEdiForm` class defines
|
||||||
@ -63,7 +64,7 @@ class Ui_ProjectorEditForm(object):
|
|||||||
self.dialog_layout = QGridLayout(edit_projector_dialog)
|
self.dialog_layout = QGridLayout(edit_projector_dialog)
|
||||||
self.dialog_layout.setObjectName('dialog_layout')
|
self.dialog_layout.setObjectName('dialog_layout')
|
||||||
self.dialog_layout.setSpacing(8)
|
self.dialog_layout.setSpacing(8)
|
||||||
self.dialog_layout.setContentsMargins(8,8,8,8)
|
self.dialog_layout.setContentsMargins(8, 8, 8, 8)
|
||||||
# IP Address
|
# IP Address
|
||||||
self.ip_label = QLabel(edit_projector_dialog)
|
self.ip_label = QLabel(edit_projector_dialog)
|
||||||
self.ip_label.setObjectName('projector_edit_ip_label')
|
self.ip_label.setObjectName('projector_edit_ip_label')
|
||||||
@ -108,8 +109,8 @@ class Ui_ProjectorEditForm(object):
|
|||||||
self.dialog_layout.addWidget(self.notes_text, 5, 1)
|
self.dialog_layout.addWidget(self.notes_text, 5, 1)
|
||||||
# Time for the buttons
|
# Time for the buttons
|
||||||
self.button_box = QDialogButtonBox(QDialogButtonBox.Help |
|
self.button_box = QDialogButtonBox(QDialogButtonBox.Help |
|
||||||
QDialogButtonBox.Save |
|
QDialogButtonBox.Save |
|
||||||
QDialogButtonBox.Cancel)
|
QDialogButtonBox.Cancel)
|
||||||
self.dialog_layout.addWidget(self.button_box, 8, 0, 1, 2)
|
self.dialog_layout.addWidget(self.button_box, 8, 0, 1, 2)
|
||||||
|
|
||||||
def retranslateUi(self, edit_projector_dialog):
|
def retranslateUi(self, edit_projector_dialog):
|
||||||
@ -134,6 +135,7 @@ class Ui_ProjectorEditForm(object):
|
|||||||
self.notes_label.setText(translate('OpenLP.ProjectorEditForm', 'Notes'))
|
self.notes_label.setText(translate('OpenLP.ProjectorEditForm', 'Notes'))
|
||||||
self.notes_text.insertPlainText(self.projector.notes)
|
self.notes_text.insertPlainText(self.projector.notes)
|
||||||
|
|
||||||
|
|
||||||
class ProjectorEditForm(QDialog, Ui_ProjectorEditForm):
|
class ProjectorEditForm(QDialog, Ui_ProjectorEditForm):
|
||||||
"""
|
"""
|
||||||
Class to add or edit a projector entry in the database.
|
Class to add or edit a projector entry in the database.
|
||||||
|
@ -45,7 +45,6 @@ from openlp.core.lib.ui import create_widget_action
|
|||||||
from openlp.core.lib.projector.constants import *
|
from openlp.core.lib.projector.constants import *
|
||||||
from openlp.core.lib.projector.db import ProjectorDB
|
from openlp.core.lib.projector.db import ProjectorDB
|
||||||
from openlp.core.lib.projector.pjlink1 import PJLink1
|
from openlp.core.lib.projector.pjlink1 import PJLink1
|
||||||
#from openlp.core.ui.projector.wizard import ProjectorWizard
|
|
||||||
from openlp.core.ui.projector.editform import ProjectorEditForm
|
from openlp.core.ui.projector.editform import ProjectorEditForm
|
||||||
|
|
||||||
# Dict for matching projector status to display icon
|
# Dict for matching projector status to display icon
|
||||||
|
Loading…
Reference in New Issue
Block a user