forked from openlp/openlp
Move network code to initialise(). Add weight to plugin attibutes documentation
This commit is contained in:
parent
3c4e9a957f
commit
0efcf15752
@ -45,6 +45,9 @@ class Plugin(object):
|
||||
``log``
|
||||
A log object used to log debugging messages. This is pre-instantiated.
|
||||
|
||||
``weight``
|
||||
A numerical value used to order the plugins.
|
||||
|
||||
**Hook Functions**
|
||||
|
||||
``check_pre_conditions()``
|
||||
|
@ -35,10 +35,6 @@ class RemotesPlugin(Plugin):
|
||||
# Call the parent constructor
|
||||
Plugin.__init__(self, u'Remotes', u'1.9.0', plugin_helpers)
|
||||
self.weight = -1
|
||||
self.server = QtNetwork.QUdpSocket()
|
||||
self.server.bind(int(self.config.get_config(u'remote port', 4316)))
|
||||
QtCore.QObject.connect(self.server,
|
||||
QtCore.SIGNAL(u'readyRead()'), self.readData)
|
||||
|
||||
def check_pre_conditions(self):
|
||||
"""
|
||||
@ -51,6 +47,12 @@ class RemotesPlugin(Plugin):
|
||||
else:
|
||||
return False
|
||||
|
||||
def initialise(self):
|
||||
self.server = QtNetwork.QUdpSocket()
|
||||
self.server.bind(int(self.config.get_config(u'remote port', 4316)))
|
||||
QtCore.QObject.connect(self.server,
|
||||
QtCore.SIGNAL(u'readyRead()'), seld.readData)
|
||||
|
||||
def get_settings_tab(self):
|
||||
"""
|
||||
Create the settings Tab
|
||||
|
Loading…
Reference in New Issue
Block a user