← Back to team overview

openlp-core team mailing list archive

[Merge] lp:~googol-hush/openlp/trivial into lp:openlp

 

Andreas Preikschat has proposed merging lp:~googol-hush/openlp/trivial into lp:openlp.

Requested reviews:
  Raoul Snyman (raoul-snyman)
  Tim Bentley (trb143)


Hello!

Replaced 'songusagemanager' by 'manager' which should fix bug #667531.


-- 
https://code.launchpad.net/~googol-hush/openlp/trivial/+merge/39539
Your team OpenLP Core is subscribed to branch lp:openlp.
=== modified file 'openlp/plugins/custom/customplugin.py'
--- openlp/plugins/custom/customplugin.py	2010-10-27 15:30:30 +0000
+++ openlp/plugins/custom/customplugin.py	2010-10-28 15:18:46 +0000
@@ -59,7 +59,7 @@
         return CustomTab(self.name, visible_name[u'title'])
 
     def getMediaManagerItem(self):
-        # Create the CustomManagerItem object
+        # Create the ManagerItem object
         return CustomMediaItem(self, self, self.icon)
 
     def about(self):
@@ -76,7 +76,7 @@
 
         Returns True if the theme is being used, otherwise returns False.
         """
-        if self.custommanager.get_all_objects(CustomSlide,
+        if self.manager.get_all_objects(CustomSlide,
             CustomSlide.theme_name == theme):
             return True
         return False
@@ -92,11 +92,11 @@
         ``newTheme``
             The new name the plugin should now use.
         """
-        customsUsingTheme = self.custommanager.get_all_objects(CustomSlide,
+        customsUsingTheme = self.manager.get_all_objects(CustomSlide,
             CustomSlide.theme_name == oldTheme)
         for custom in customsUsingTheme:
             custom.theme_name = newTheme
-            self.custommanager.save_object(custom)
+            self.manager.save_object(custom)
 
     def setPluginTextStrings(self):
         """

=== modified file 'openlp/plugins/custom/lib/mediaitem.py'
--- openlp/plugins/custom/lib/mediaitem.py	2010-10-27 15:30:30 +0000
+++ openlp/plugins/custom/lib/mediaitem.py	2010-10-28 15:18:46 +0000
@@ -140,7 +140,7 @@
             id_list = [(item.data(QtCore.Qt.UserRole)).toInt()[0]
                 for item in self.listView.selectedIndexes()]
             for id in id_list:
-                self.parent.custommanager.delete_object(CustomSlide, id)
+                self.parent.manager.delete_object(CustomSlide, id)
             for row in row_list:
                 self.listView.takeItem(row)
 
@@ -162,7 +162,7 @@
         service_item.add_capability(ItemCapabilities.AllowsEdit)
         service_item.add_capability(ItemCapabilities.AllowsPreview)
         service_item.add_capability(ItemCapabilities.AllowsLoop)
-        customSlide = self.parent.custommanager.get_object(CustomSlide, item_id)
+        customSlide = self.parent.manager.get_object(CustomSlide, item_id)
         title = customSlide.title
         credit = customSlide.credits
         service_item.editId = item_id

=== modified file 'openlp/plugins/songusage/forms/songusagedeleteform.py'
--- openlp/plugins/songusage/forms/songusagedeleteform.py	2010-09-14 18:18:47 +0000
+++ openlp/plugins/songusage/forms/songusagedeleteform.py	2010-10-28 15:18:46 +0000
@@ -34,11 +34,11 @@
     """
     Class documentation goes here.
     """
-    def __init__(self, songusagemanager, parent):
+    def __init__(self, manager, parent):
         """
         Constructor
         """
-        self.songusagemanager = songusagemanager
+        self.manager = manager
         QtGui.QDialog.__init__(self, parent)
         self.setupUi(self)
 
@@ -53,6 +53,6 @@
             QtGui.QMessageBox.Cancel)
         if ret == QtGui.QMessageBox.Ok:
             deleteDate = self.deleteCalendar.selectedDate().toPyDate()
-            self.songusagemanager.delete_all_objects(SongUsageItem,
+            self.manager.delete_all_objects(SongUsageItem,
                 SongUsageItem.usagedate <= deleteDate)
         self.close()

=== modified file 'openlp/plugins/songusage/forms/songusagedetailform.py'
--- openlp/plugins/songusage/forms/songusagedetailform.py	2010-09-14 18:18:47 +0000
+++ openlp/plugins/songusage/forms/songusagedetailform.py	2010-10-28 15:18:46 +0000
@@ -76,7 +76,7 @@
         filename = u'usage_detail_%s_%s.txt' % (
             self.fromDate.selectedDate().toString(u'ddMMyyyy'),
             self.toDate.selectedDate().toString(u'ddMMyyyy'))
-        usage = self.plugin.songusagemanager.get_all_objects(
+        usage = self.plugin.manager.get_all_objects(
             SongUsageItem, and_(
             SongUsageItem.usagedate >= self.fromDate.selectedDate().toPyDate(),
             SongUsageItem.usagedate < self.toDate.selectedDate().toPyDate()),

=== modified file 'openlp/plugins/songusage/songusageplugin.py'
--- openlp/plugins/songusage/songusageplugin.py	2010-10-27 15:30:30 +0000
+++ openlp/plugins/songusage/songusageplugin.py	2010-10-28 15:18:46 +0000
@@ -44,7 +44,7 @@
         Plugin.__init__(self, u'SongUsage', u'1.9.3', plugin_helpers)
         self.weight = -4
         self.icon = build_icon(u':/plugins/plugin_songusage.png')
-        self.songusagemanager = None
+        self.manager = None
         self.songusageActive = False
 
     def addToolsMenuItem(self, tools_menu):
@@ -115,9 +115,9 @@
             self.settingsSection + u'/active',
             QtCore.QVariant(False)).toBool()
         self.SongUsageStatus.setChecked(self.SongUsageActive)
-        if self.songusagemanager is None:
-            self.songusagemanager = Manager(u'songusage', init_schema)
-        self.SongUsagedeleteform = SongUsageDeleteForm(self.songusagemanager,
+        if self.manager is None:
+            self.manager = Manager(u'songusage', init_schema)
+        self.SongUsagedeleteform = SongUsageDeleteForm(self.manager,
             self.formparent)
         self.SongUsagedetailform = SongUsageDetailForm(self, self.formparent)
         self.SongUsageMenu.menuAction().setVisible(True)
@@ -148,7 +148,7 @@
             song_usage_item.authors = u''
             for author in audit[1]:
                 song_usage_item.authors += author + u' '
-            self.songusagemanager.save_object(song_usage_item)
+            self.manager.save_object(song_usage_item)
 
     def onSongUsageDelete(self):
         self.SongUsagedeleteform.exec_()


Follow ups