forked from openlp/openlp
Make plugin config updates generic
Fix up some copyright issues missed
This commit is contained in:
parent
283d85fbd9
commit
d00840d1e0
@ -213,9 +213,10 @@ class EventReceiver(QtCore.QObject):
|
|||||||
``{plugin}_add_service_item``
|
``{plugin}_add_service_item``
|
||||||
Ask the plugin to push the selected items to the service item.
|
Ask the plugin to push the selected items to the service item.
|
||||||
|
|
||||||
``{plugin}_service_load``
|
|
||||||
Ask the plugin to process an individual service item after it has been
|
``{plugin}_config_updated``
|
||||||
loaded.
|
The Plugn's config has changed so lets do some processing.
|
||||||
|
|
||||||
|
|
||||||
``alerts_text``
|
``alerts_text``
|
||||||
Displays an alert message.
|
Displays an alert message.
|
||||||
|
@ -173,6 +173,9 @@ class Plugin(QtCore.QObject):
|
|||||||
QtCore.QObject.connect(Receiver.get_receiver(),
|
QtCore.QObject.connect(Receiver.get_receiver(),
|
||||||
QtCore.SIGNAL(u'%s_add_service_item' % self.name),
|
QtCore.SIGNAL(u'%s_add_service_item' % self.name),
|
||||||
self.processAddServiceEvent)
|
self.processAddServiceEvent)
|
||||||
|
QtCore.QObject.connect(Receiver.get_receiver(),
|
||||||
|
QtCore.SIGNAL(u'%s_config_updated' % self.name),
|
||||||
|
self.configUpdated)
|
||||||
|
|
||||||
def checkPreConditions(self):
|
def checkPreConditions(self):
|
||||||
"""
|
"""
|
||||||
@ -395,3 +398,9 @@ class Plugin(QtCore.QObject):
|
|||||||
Add html code to htmlbuilder.
|
Add html code to htmlbuilder.
|
||||||
"""
|
"""
|
||||||
return u''
|
return u''
|
||||||
|
|
||||||
|
def configUpdatedl(self):
|
||||||
|
"""
|
||||||
|
The plugin's config has changed
|
||||||
|
"""
|
||||||
|
pass
|
||||||
|
@ -4,12 +4,12 @@
|
|||||||
###############################################################################
|
###############################################################################
|
||||||
# OpenLP - Open Source Lyrics Projection #
|
# OpenLP - Open Source Lyrics Projection #
|
||||||
# --------------------------------------------------------------------------- #
|
# --------------------------------------------------------------------------- #
|
||||||
# Copyright (c) 2008-2011 Raoul Snyman #
|
# Copyright (c) 2008-2012 Raoul Snyman #
|
||||||
# Portions copyright (c) 2008-2011 Tim Bentley, Jonathan Corwin, Michael #
|
# Portions copyright (c) 2008-2012 Tim Bentley, Gerald Britton, Jonathan #
|
||||||
# Gorven, Scott Guerrieri, Matthias Hub, Meinert Jordan, Armin Köhler, #
|
# Corwin, Michael Gorven, Scott Guerrieri, Matthias Hub, Meinert Jordan, #
|
||||||
# Andreas Preikschat, Mattias Põldaru, Christian Richter, Philip Ridout, #
|
# Armin Köhler, Joshua Miller, Stevan Pettit, Andreas Preikschat, Mattias #
|
||||||
# Jeffrey Smith, Maikel Stuivenberg, Martin Thompson, Jon Tibble, Frode #
|
# Põldaru, Christian Richter, Philip Ridout, Simon Scudder, Jeffrey Smith, #
|
||||||
# Woldsund #
|
# Maikel Stuivenberg, Martin Thompson, Jon Tibble, Frode Woldsund #
|
||||||
# --------------------------------------------------------------------------- #
|
# --------------------------------------------------------------------------- #
|
||||||
# This program is free software; you can redistribute it and/or modify it #
|
# This program is free software; you can redistribute it and/or modify it #
|
||||||
# under the terms of the GNU General Public License as published by the Free #
|
# under the terms of the GNU General Public License as published by the Free #
|
||||||
|
@ -1,12 +1,12 @@
|
|||||||
/*****************************************************************************
|
/*****************************************************************************
|
||||||
* OpenLP - Open Source Lyrics Projection *
|
* OpenLP - Open Source Lyrics Projection *
|
||||||
* ------------------------------------------------------------------------- *
|
* ------------------------------------------------------------------------- *
|
||||||
* Copyright (c) 2008-2010 Raoul Snyman *
|
* Copyright (c) 2008-2012 Raoul Snyman *
|
||||||
* Portions copyright (c) 2008-2010 Tim Bentley, Jonathan Corwin, Michael *
|
* Portions copyright (c) 2008-2012 Tim Bentley, Gerald Britton, Jonathan *
|
||||||
* Gorven, Scott Guerrieri, Matthias Hub, Meinert Jordan, Armin Köhler, *
|
* Corwin, Michael Gorven, Scott Guerrieri, Matthias Hub, Meinert Jordan, *
|
||||||
* Andreas Preikschat, Mattias Põldaru, Christian Richter, Philip Ridout, *
|
* Armin Köhler, Joshua Miller, Stevan Pettit, Andreas Preikschat, Mattias *
|
||||||
* Jeffrey Smith, Maikel Stuivenberg, Martin Thompson, Jon Tibble, Frode *
|
* Põldaru, Christian Richter, Philip Ridout, Simon Scudder, Jeffrey Smith, *
|
||||||
* Woldsund *
|
* Maikel Stuivenberg, Martin Thompson, Jon Tibble, Frode Woldsund *
|
||||||
* ------------------------------------------------------------------------- *
|
* ------------------------------------------------------------------------- *
|
||||||
* This program is free software; you can redistribute it and/or modify it *
|
* This program is free software; you can redistribute it and/or modify it *
|
||||||
* under the terms of the GNU General Public License as published by the *
|
* under the terms of the GNU General Public License as published by the *
|
||||||
|
@ -1,12 +1,12 @@
|
|||||||
/*****************************************************************************
|
/*****************************************************************************
|
||||||
* OpenLP - Open Source Lyrics Projection *
|
* OpenLP - Open Source Lyrics Projection *
|
||||||
* ------------------------------------------------------------------------- *
|
* ------------------------------------------------------------------------- *
|
||||||
* Copyright (c) 2008-2010 Raoul Snyman *
|
* Copyright (c) 2008-2012 Raoul Snyman *
|
||||||
* Portions copyright (c) 2008-2010 Tim Bentley, Jonathan Corwin, Michael *
|
* Portions copyright (c) 2008-2012 Tim Bentley, Gerald Britton, Jonathan *
|
||||||
* Gorven, Scott Guerrieri, Matthias Hub, Meinert Jordan, Armin Köhler, *
|
* Corwin, Michael Gorven, Scott Guerrieri, Matthias Hub, Meinert Jordan, *
|
||||||
* Andreas Preikschat, Mattias Põldaru, Christian Richter, Philip Ridout, *
|
* Armin Köhler, Joshua Miller, Stevan Pettit, Andreas Preikschat, Mattias *
|
||||||
* Jeffrey Smith, Maikel Stuivenberg, Martin Thompson, Jon Tibble, Frode *
|
* Põldaru, Christian Richter, Philip Ridout, Simon Scudder, Jeffrey Smith, *
|
||||||
* Woldsund *
|
* Maikel Stuivenberg, Martin Thompson, Jon Tibble, Frode Woldsund *
|
||||||
* ------------------------------------------------------------------------- *
|
* ------------------------------------------------------------------------- *
|
||||||
* This program is free software; you can redistribute it and/or modify it *
|
* This program is free software; you can redistribute it and/or modify it *
|
||||||
* under the terms of the GNU General Public License as published by the *
|
* under the terms of the GNU General Public License as published by the *
|
||||||
|
@ -1,12 +1,12 @@
|
|||||||
/*****************************************************************************
|
/*****************************************************************************
|
||||||
* OpenLP - Open Source Lyrics Projection *
|
* OpenLP - Open Source Lyrics Projection *
|
||||||
* ------------------------------------------------------------------------- *
|
* ------------------------------------------------------------------------- *
|
||||||
* Copyright (c) 2008-2010 Raoul Snyman *
|
* Copyright (c) 2008-2012 Raoul Snyman *
|
||||||
* Portions copyright (c) 2008-2010 Tim Bentley, Jonathan Corwin, Michael *
|
* Portions copyright (c) 2008-2012 Tim Bentley, Gerald Britton, Jonathan *
|
||||||
* Gorven, Scott Guerrieri, Matthias Hub, Meinert Jordan, Armin K<EFBFBD>hler, *
|
* Corwin, Michael Gorven, Scott Guerrieri, Matthias Hub, Meinert Jordan, *
|
||||||
* Andreas Preikschat, Mattias P<EFBFBD>ldaru, Christian Richter, Philip Ridout, *
|
* Armin Köhler, Joshua Miller, Stevan Pettit, Andreas Preikschat, Mattias *
|
||||||
* Jeffrey Smith, Maikel Stuivenberg, Martin Thompson, Jon Tibble, Frode *
|
* Põldaru, Christian Richter, Philip Ridout, Simon Scudder, Jeffrey Smith, *
|
||||||
* Woldsund *
|
* Maikel Stuivenberg, Martin Thompson, Jon Tibble, Frode Woldsund *
|
||||||
* ------------------------------------------------------------------------- *
|
* ------------------------------------------------------------------------- *
|
||||||
* This program is free software; you can redistribute it and/or modify it *
|
* This program is free software; you can redistribute it and/or modify it *
|
||||||
* under the terms of the GNU General Public License as published by the *
|
* under the terms of the GNU General Public License as published by the *
|
||||||
|
@ -4,12 +4,12 @@
|
|||||||
###############################################################################
|
###############################################################################
|
||||||
# OpenLP - Open Source Lyrics Projection #
|
# OpenLP - Open Source Lyrics Projection #
|
||||||
# --------------------------------------------------------------------------- #
|
# --------------------------------------------------------------------------- #
|
||||||
# Copyright (c) 2008-2011 Raoul Snyman #
|
# Copyright (c) 2008-2012 Raoul Snyman #
|
||||||
# Portions copyright (c) 2008-2011 Tim Bentley, Jonathan Corwin, Michael #
|
# Portions copyright (c) 2008-2012 Tim Bentley, Gerald Britton, Jonathan #
|
||||||
# Gorven, Scott Guerrieri, Matthias Hub, Meinert Jordan, Armin Köhler, #
|
# Corwin, Michael Gorven, Scott Guerrieri, Matthias Hub, Meinert Jordan, #
|
||||||
# Andreas Preikschat, Mattias Põldaru, Christian Richter, Philip Ridout, #
|
# Armin Köhler, Joshua Miller, Stevan Pettit, Andreas Preikschat, Mattias #
|
||||||
# Jeffrey Smith, Maikel Stuivenberg, Martin Thompson, Jon Tibble, Frode #
|
# Põldaru, Christian Richter, Philip Ridout, Simon Scudder, Jeffrey Smith, #
|
||||||
# Woldsund #
|
# Maikel Stuivenberg, Martin Thompson, Jon Tibble, Frode Woldsund #
|
||||||
# --------------------------------------------------------------------------- #
|
# --------------------------------------------------------------------------- #
|
||||||
# This program is free software; you can redistribute it and/or modify it #
|
# This program is free software; you can redistribute it and/or modify it #
|
||||||
# under the terms of the GNU General Public License as published by the Free #
|
# under the terms of the GNU General Public License as published by the Free #
|
||||||
|
@ -1,12 +1,12 @@
|
|||||||
/*****************************************************************************
|
/*****************************************************************************
|
||||||
* OpenLP - Open Source Lyrics Projection *
|
* OpenLP - Open Source Lyrics Projection *
|
||||||
* ------------------------------------------------------------------------- *
|
* ------------------------------------------------------------------------- *
|
||||||
* Copyright (c) 2008-2010 Raoul Snyman *
|
* Copyright (c) 2008-2012 Raoul Snyman *
|
||||||
* Portions copyright (c) 2008-2010 Tim Bentley, Jonathan Corwin, Michael *
|
* Portions copyright (c) 2008-2012 Tim Bentley, Gerald Britton, Jonathan *
|
||||||
* Gorven, Scott Guerrieri, Matthias Hub, Meinert Jordan, Armin Köhler, *
|
* Corwin, Michael Gorven, Scott Guerrieri, Matthias Hub, Meinert Jordan, *
|
||||||
* Andreas Preikschat, Mattias Põldaru, Christian Richter, Philip Ridout, *
|
* Armin Köhler, Joshua Miller, Stevan Pettit, Andreas Preikschat, Mattias *
|
||||||
* Jeffrey Smith, Maikel Stuivenberg, Martin Thompson, Jon Tibble, Frode *
|
* Põldaru, Christian Richter, Philip Ridout, Simon Scudder, Jeffrey Smith, *
|
||||||
* Woldsund *
|
* Maikel Stuivenberg, Martin Thompson, Jon Tibble, Frode Woldsund *
|
||||||
* ------------------------------------------------------------------------- *
|
* ------------------------------------------------------------------------- *
|
||||||
* This program is free software; you can redistribute it and/or modify it *
|
* This program is free software; you can redistribute it and/or modify it *
|
||||||
* under the terms of the GNU General Public License as published by the *
|
* under the terms of the GNU General Public License as published by the *
|
||||||
|
@ -27,10 +27,7 @@
|
|||||||
|
|
||||||
import logging
|
import logging
|
||||||
|
|
||||||
from PyQt4 import QtCore
|
from openlp.core.lib import Plugin, StringContent, translate, build_icon
|
||||||
|
|
||||||
from openlp.core.lib import Plugin, StringContent, translate, build_icon,\
|
|
||||||
Receiver
|
|
||||||
from openlp.plugins.remotes.lib import RemoteTab, HttpServer
|
from openlp.plugins.remotes.lib import RemoteTab, HttpServer
|
||||||
|
|
||||||
log = logging.getLogger(__name__)
|
log = logging.getLogger(__name__)
|
||||||
@ -48,9 +45,7 @@ class RemotesPlugin(Plugin):
|
|||||||
self.icon = build_icon(self.icon_path)
|
self.icon = build_icon(self.icon_path)
|
||||||
self.weight = -1
|
self.weight = -1
|
||||||
self.server = None
|
self.server = None
|
||||||
QtCore.QObject.connect(Receiver.get_receiver(),
|
|
||||||
QtCore.SIGNAL(u'remote_config_updated'),
|
|
||||||
self.config_updated)
|
|
||||||
|
|
||||||
def initialise(self):
|
def initialise(self):
|
||||||
"""
|
"""
|
||||||
@ -93,7 +88,7 @@ class RemotesPlugin(Plugin):
|
|||||||
u'title': translate('RemotePlugin', 'Remote', 'container title')
|
u'title': translate('RemotePlugin', 'Remote', 'container title')
|
||||||
}
|
}
|
||||||
|
|
||||||
def config_updated(self):
|
def configUpdated(self):
|
||||||
"""
|
"""
|
||||||
Called when Config is changed to restart the server on new address or
|
Called when Config is changed to restart the server on new address or
|
||||||
port
|
port
|
||||||
|
Loading…
Reference in New Issue
Block a user