openlp-core team mailing list archive
-
openlp-core team
-
Mailing list archive
-
Message #02877
[Merge] lp:~trb143/openlp/bugfixes into lp:openlp
Tim Bentley has proposed merging lp:~trb143/openlp/bugfixes into lp:openlp.
Requested reviews:
OpenLP Core (openlp-core)
Fix Song usage try 2.
Fix bug #598407
--
https://code.launchpad.net/~trb143/openlp/bugfixes/+merge/31575
Your team OpenLP Core is requested to review the proposed merge of lp:~trb143/openlp/bugfixes into lp:openlp.
=== modified file 'openlp/core/lib/serviceitem.py'
--- openlp/core/lib/serviceitem.py 2010-07-27 10:20:20 +0000
+++ openlp/core/lib/serviceitem.py 2010-08-02 19:25:57 +0000
@@ -86,7 +86,7 @@
self.service_item_type = None
self._raw_frames = []
self._display_frames = []
- self._uuid = unicode(uuid.uuid1())
+ self._uuid = 0
self.notes = u''
self.from_plugin = False
self.capabilities = []
@@ -94,6 +94,9 @@
self.cache = {}
self.icon = None
+ def _new_item(self):
+ self._uuid = unicode(uuid.uuid1())
+
def add_capability(self, capability):
"""
Add an ItemCapability to a ServiceItem
@@ -200,6 +203,7 @@
self.service_item_type = ServiceItemType.Image
self._raw_frames.append(
{u'title': title, u'image': image, u'path': path})
+ self._new_item()
def add_from_text(self, title, raw_slide, verse_tag=None):
"""
@@ -215,6 +219,7 @@
title = title.split(u'\n')[0]
self._raw_frames.append(
{u'title': title, u'raw_slide': raw_slide, u'verseTag':verse_tag})
+ self._new_item()
def add_from_command(self, path, file_name, image):
"""
@@ -232,6 +237,7 @@
self.service_item_type = ServiceItemType.Command
self._raw_frames.append(
{u'title': file_name, u'image': image, u'path': path})
+ self._new_item()
def get_service_repr(self):
"""
=== modified file 'openlp/plugins/songs/lib/mediaitem.py'
--- openlp/plugins/songs/lib/mediaitem.py 2010-07-27 09:32:52 +0000
+++ openlp/plugins/songs/lib/mediaitem.py 2010-08-02 19:25:57 +0000
@@ -370,6 +370,6 @@
translate('SongsPlugin.MediaItem', 'CCLI Licence: ') + ccli))
service_item.raw_footer = raw_footer
service_item.audit = [
- song.title, author_audit, song.copyright, song.ccli_number
+ song.title, author_audit, song.copyright, unicode(song.ccli_number)
]
return True
=== modified file 'openlp/plugins/songusage/songusageplugin.py'
--- openlp/plugins/songusage/songusageplugin.py 2010-07-31 00:34:37 +0000
+++ openlp/plugins/songusage/songusageplugin.py 2010-08-02 19:25:57 +0000
@@ -109,7 +109,7 @@
log.info(u'SongUsage Initialising')
Plugin.initialise(self)
QtCore.QObject.connect(Receiver.get_receiver(),
- QtCore.SIGNAL(u'songs_live_started'),
+ QtCore.SIGNAL(u'slidecontroller_live_started'),
self.onReceiveSongUsage)
self.SongUsageActive = QtCore.QSettings().value(
self.settingsSection + u'/active',
@@ -133,11 +133,11 @@
QtCore.QSettings().setValue(self.settingsSection + u'/active',
QtCore.QVariant(self.SongUsageActive))
- def onReceiveSongUsage(self, items):
- """
- SongUsage a live song from SlideController
- """
- audit = items[0].audit
+ def onReceiveSongUsage(self, item):
+ """
+ Song Usage for live song from SlideController
+ """
+ audit = item[0].audit
if self.SongUsageActive and audit:
song_usage_item = SongUsageItem()
song_usage_item.usagedate = datetime.today()
Follow ups