← Back to team overview

openlp-core team mailing list archive

[Merge] lp:~meths/openlp/trivialfixes into lp:openlp

 

Jon Tibble has proposed merging lp:~meths/openlp/trivialfixes into lp:openlp.

Requested reviews:
  OpenLP Core (openlp-core)

For more details, see:
https://code.launchpad.net/~meths/openlp/trivialfixes/+merge/49475

UiStrings and SongStrings
-- 
https://code.launchpad.net/~meths/openlp/trivialfixes/+merge/49475
Your team OpenLP Core is requested to review the proposed merge of lp:~meths/openlp/trivialfixes into lp:openlp.
=== modified file 'openlp/core/lib/mediamanageritem.py'
--- openlp/core/lib/mediamanageritem.py	2011-02-11 04:04:05 +0000
+++ openlp/core/lib/mediamanageritem.py	2011-02-11 22:36:52 +0000
@@ -34,6 +34,7 @@
 from openlp.core.lib import context_menu_action, context_menu_separator, \
     SettingsManager, OpenLPToolbar, ServiceItem, StringContent, build_icon, \
     translate, Receiver, ListWidgetWithDnD
+from openlp.core.lib.ui import UiStrings
 
 log = logging.getLogger(__name__)
 
@@ -449,8 +450,7 @@
         Add a selected item to the current service
         """
         if not self.listView.selectedIndexes() and not self.remoteTriggered:
-            QtGui.QMessageBox.information(self,
-                translate('OpenLP.MediaManagerItem', 'No Items Selected'),
+            QtGui.QMessageBox.information(self, UiStrings.NISp,
                 translate('OpenLP.MediaManagerItem',
                     'You must select one or more items.'))
         else:
@@ -476,17 +476,14 @@
         Add a selected item to an existing item in the current service.
         """
         if not self.listView.selectedIndexes() and not self.remoteTriggered:
-            QtGui.QMessageBox.information(self,
-                translate('OpenLP.MediaManagerItem', 'No Items Selected'),
+            QtGui.QMessageBox.information(self, UiStrings.NISp,
                 translate('OpenLP.MediaManagerItem',
                     'You must select one or more items'))
         else:
             log.debug(u'%s Add requested', self.plugin.name)
             serviceItem = self.parent.serviceManager.getServiceItem()
             if not serviceItem:
-                QtGui.QMessageBox.information(self,
-                    translate('OpenLP.MediaManagerItem',
-                        'No Service Item Selected'),
+                QtGui.QMessageBox.information(self, UiStrings.NISs,
                     translate('OpenLP.MediaManagerItem',
                         'You must select an existing service item to add to.'))
             elif self.plugin.name.lower() == serviceItem.name.lower():

=== modified file 'openlp/core/lib/theme.py'
--- openlp/core/lib/theme.py	2011-02-10 23:00:15 +0000
+++ openlp/core/lib/theme.py	2011-02-11 22:36:52 +0000
@@ -178,9 +178,9 @@
         """
         Return a string representation of a horizontal type.
         """
-        if horizontal_type == Horizontal.Right:
+        if horizontal_type == HorizontalType.Right:
             return u'right'
-        elif horizontal_type == Horizontal.Center:
+        elif horizontal_type == HorizontalType.Center:
             return u'center'
         else:
             return u'left'

=== modified file 'openlp/core/lib/ui.py'
--- openlp/core/lib/ui.py	2011-02-10 22:49:30 +0000
+++ openlp/core/lib/ui.py	2011-02-11 22:36:52 +0000
@@ -46,7 +46,6 @@
         'Add the selected %s to the service.'))
     Advanced = translate('OpenLP.Ui', 'Advanced')
     AllFiles = translate('OpenLP.Ui', 'All Files')
-    Authors = translate('OpenLP.Ui', 'Authors')
     CreateANew = unicode(translate('OpenLP.Ui', 'Create a new %s.'))
     Delete = translate('OpenLP.Ui', '&Delete')
     DeleteSelect = unicode(translate('OpenLP.Ui', 'Delete the selected %s.'))
@@ -54,18 +53,26 @@
     Edit = translate('OpenLP.Ui', '&Edit')
     EditSelect = unicode(translate('OpenLP.Ui', 'Edit the selected %s.'))
     EditType = unicode(translate('OpenLP.Ui', 'Edit %s'))
+    EmptyField = translate('OpenLP.Ui', 'Empty Field')
     Error = translate('OpenLP.Ui', 'Error')
     ExportType = unicode(translate('OpenLP.Ui', 'Export %s'))
     Import = translate('OpenLP.Ui', 'Import')
     ImportType = unicode(translate('OpenLP.Ui', 'Import %s'))
     Live = translate('OpenLP.Ui', 'Live')
+    LivePanel = translate('OpenLP.Ui', 'Live Panel')
     Load = translate('OpenLP.Ui', 'Load')
     LoadANew = unicode(translate('OpenLP.Ui', 'Load a new %s.'))
+    MediaManager = translate('OpenLP.Ui', 'Media Manager')
     New = translate('OpenLP.Ui', 'New')
     NewType = unicode(translate('OpenLP.Ui', 'New %s'))
+    NFSs = translate('OpenLP.Ui', 'No File Selected', 'Singular')
+    NFSp = translate('OpenLP.Ui', 'No Files Selected', 'Plural')
+    NISs = translate('OpenLP.Ui', 'No Item Selected', 'Singular')
+    NISp = translate('OpenLP.Ui', 'No Items Selected', 'Plural')
     OLPV2 = translate('OpenLP.Ui', 'OpenLP 2.0')
     OpenType = unicode(translate('OpenLP.Ui', 'Open %s'))
     Preview = translate('OpenLP.Ui', 'Preview')
+    PreviewPanel = translate('OpenLP.Ui', 'Preview Panel')
     PreviewSelect = unicode(translate('OpenLP.Ui', 'Preview the selected %s.'))
     ReplaceBG = translate('OpenLP.Ui', 'Replace Background')
     ReplaceLiveBG = translate('OpenLP.Ui', 'Replace Live Background')
@@ -75,8 +82,13 @@
     SendSelectLive = unicode(translate('OpenLP.Ui',
         'Send the selected %s live.'))
     Service = translate('OpenLP.Ui', 'Service')
-    Theme = translate('OpenLP.Ui', 'Theme')
-    Themes = translate('OpenLP.Ui', 'Themes')
+    ServiceManager = translate('OpenLP.Ui', 'Service Manager')
+    Theme = translate('OpenLP.Ui', 'Theme', 'Singular')
+    Themes = translate('OpenLP.Ui', 'Themes', 'Plural')
+    ThemeManager = translate('OpenLP.Ui', 'Theme Manager')
+    ToggleType = unicode(translate('OpenLP.Ui', 'Toggle %s'))
+    ToggleVisibility = unicode(translate('OpenLP.Ui',
+        'Toggle the visibility of the %s.'))
 
 
 def add_welcome_page(parent, image):
@@ -168,7 +180,7 @@
     combo.setSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Fixed)
     return combo
 
-def create_delete_push_button(parent, icon=None):
+def create_delete_push_button(parent, item_name, icon=None):
     """
     Creates a standard push button with a delete label and optional icon.  The
     button is connected to the parent's ``onDeleteButtonClicked()`` method to
@@ -186,8 +198,7 @@
     delete_icon = icon if icon else u':/general/general_delete.png'
     delete_button.setIcon(build_icon(delete_icon))
     delete_button.setText(UiStrings.Delete)
-    delete_button.setToolTip(
-        translate('OpenLP.Ui', 'Delete the selected item.'))
+    delete_button.setToolTip(UiStrings.DeleteSelect % item_name)
     QtCore.QObject.connect(delete_button,
         QtCore.SIGNAL(u'clicked()'), parent.onDeleteButtonClicked)
     return delete_button

=== modified file 'openlp/core/ui/mainwindow.py'
--- openlp/core/ui/mainwindow.py	2011-02-10 22:49:30 +0000
+++ openlp/core/ui/mainwindow.py	2011-02-11 22:36:52 +0000
@@ -312,12 +312,9 @@
         self.SettingsLanguageMenu.setTitle(translate('OpenLP.MainWindow',
             '&Language'))
         self.HelpMenu.setTitle(translate('OpenLP.MainWindow', '&Help'))
-        self.mediaManagerDock.setWindowTitle(
-            translate('OpenLP.MainWindow', 'Media Manager'))
-        self.serviceManagerDock.setWindowTitle(
-            translate('OpenLP.MainWindow', 'Service Manager'))
-        self.themeManagerDock.setWindowTitle(
-            translate('OpenLP.MainWindow', 'Theme Manager'))
+        self.mediaManagerDock.setWindowTitle(UiStrings.MediaManager)
+        self.serviceManagerDock.setWindowTitle(UiStrings.ServiceManager)
+        self.themeManagerDock.setWindowTitle(UiStrings.ThemeManager)
         self.FileNewItem.setText(translate('OpenLP.MainWindow', '&New'))
         self.FileNewItem.setToolTip(UiStrings.NewType % UiStrings.Service)
         self.FileNewItem.setStatusTip(
@@ -368,41 +365,41 @@
         self.ViewMediaManagerItem.setText(
             translate('OpenLP.MainWindow', '&Media Manager'))
         self.ViewMediaManagerItem.setToolTip(
-            translate('OpenLP.MainWindow', 'Toggle Media Manager'))
-        self.ViewMediaManagerItem.setStatusTip(translate('OpenLP.MainWindow',
-            'Toggle the visibility of the media manager.'))
+            UiStrings.Toggle % UiStrings.MediaManager)
+        self.ViewMediaManagerItem.setStatusTip(
+            UiStrings.ToggleVisibility % UiStrings.MediaManager.toLower())
         self.ViewMediaManagerItem.setShortcut(
             translate('OpenLP.MainWindow', 'F8'))
         self.ViewThemeManagerItem.setText(
             translate('OpenLP.MainWindow', '&Theme Manager'))
         self.ViewThemeManagerItem.setToolTip(
-            translate('OpenLP.MainWindow', 'Toggle Theme Manager'))
-        self.ViewThemeManagerItem.setStatusTip(translate('OpenLP.MainWindow',
-            'Toggle the visibility of the theme manager.'))
+            UiStrings.Toggle % UiStrings.ThemeManager)
+        self.ViewThemeManagerItem.setStatusTip(
+            UiStrings.ToggleVisibility % UiStrings.ThemeManager.toLower())
         self.ViewThemeManagerItem.setShortcut(
             translate('OpenLP.MainWindow', 'F10'))
         self.ViewServiceManagerItem.setText(
             translate('OpenLP.MainWindow', '&Service Manager'))
         self.ViewServiceManagerItem.setToolTip(
-            translate('OpenLP.MainWindow', 'Toggle Service Manager'))
-        self.ViewServiceManagerItem.setStatusTip(translate('OpenLP.MainWindow',
-            'Toggle the visibility of the service manager.'))
+            UiStrings.Toggle % UiStrings.ServiceManager)
+        self.ViewServiceManagerItem.setStatusTip(
+            UiStrings.ToggleVisibility % UiStrings.ServiceManager.toLower())
         self.ViewServiceManagerItem.setShortcut(
             translate('OpenLP.MainWindow', 'F9'))
         self.ViewPreviewPanel.setText(
             translate('OpenLP.MainWindow', '&Preview Panel'))
         self.ViewPreviewPanel.setToolTip(
-            translate('OpenLP.MainWindow', 'Toggle Preview Panel'))
-        self.ViewPreviewPanel.setStatusTip(translate('OpenLP.MainWindow',
-            'Toggle the visibility of the preview panel.'))
+            UiStrings.Toggle % UiStrings.PreviewPanel)
+        self.ViewPreviewPanel.setStatusTip(
+            UiStrings.ToggleVisibility % UiStrings.PreviewPanel.toLower())
         self.ViewPreviewPanel.setShortcut(
             translate('OpenLP.MainWindow', 'F11'))
         self.ViewLivePanel.setText(
             translate('OpenLP.MainWindow', '&Live Panel'))
         self.ViewLivePanel.setToolTip(
-            translate('OpenLP.MainWindow', 'Toggle Live Panel'))
-        self.ViewLivePanel.setStatusTip(translate('OpenLP.MainWindow',
-            'Toggle the visibility of the live panel.'))
+            UiStrings.Toggle % UiStrings.LivePanel)
+        self.ViewLivePanel.setStatusTip(
+            UiStrings.ToggleVisibility % UiStrings.LivePanel.toLower())
         self.ViewLivePanel.setShortcut(
             translate('OpenLP.MainWindow', 'F12'))
         self.settingsPluginListItem.setText(translate('OpenLP.MainWindow',

=== modified file 'openlp/core/ui/serviceitemeditdialog.py'
--- openlp/core/ui/serviceitemeditdialog.py	2011-02-10 00:36:00 +0000
+++ openlp/core/ui/serviceitemeditdialog.py	2011-02-11 22:36:52 +0000
@@ -27,7 +27,7 @@
 from PyQt4 import QtCore, QtGui
 
 from openlp.core.lib import translate
-from openlp.core.lib.ui import create_accept_reject_button_box, \
+from openlp.core.lib.ui import UiStrings, create_accept_reject_button_box, \
     create_delete_push_button, create_up_down_push_button_set
 
 class Ui_ServiceItemEditDialog(object):
@@ -41,7 +41,8 @@
         self.dialogLayout.addWidget(self.listWidget, 0, 0)
         self.buttonLayout = QtGui.QVBoxLayout()
         self.buttonLayout.setObjectName(u'buttonLayout')
-        self.deleteButton = create_delete_push_button(serviceItemEditDialog)
+        self.deleteButton = create_delete_push_button(
+            serviceItemEditDialog, UiStrings.Service.toLower())
         self.buttonLayout.addWidget(self.deleteButton)
         self.buttonLayout.addStretch()
         self.upButton, self.downButton = create_up_down_push_button_set(

=== modified file 'openlp/plugins/alerts/forms/alertdialog.py'
--- openlp/plugins/alerts/forms/alertdialog.py	2011-02-05 01:24:19 +0000
+++ openlp/plugins/alerts/forms/alertdialog.py	2011-02-11 22:36:52 +0000
@@ -26,7 +26,7 @@
 
 from PyQt4 import QtCore, QtGui
 
-from openlp.core.lib import build_icon, translate
+from openlp.core.lib import StringContent, build_icon, translate
 from openlp.core.lib.ui import create_delete_push_button
 
 class Ui_AlertDialog(object):
@@ -66,7 +66,8 @@
         self.saveButton.setIcon(build_icon(u':/general/general_save.png'))
         self.saveButton.setObjectName(u'saveButton')
         self.manageButtonLayout.addWidget(self.saveButton)
-        self.deleteButton = create_delete_push_button(alertDialog)
+        self.deleteButton = create_delete_push_button(alertDialog,
+            self.parent.getString(StringContent.Name)[u'singular'].toLower())
         self.deleteButton.setEnabled(False)
         self.manageButtonLayout.addWidget(self.deleteButton)
         self.manageButtonLayout.addStretch()

=== modified file 'openlp/plugins/bibles/forms/bibleimportform.py'
--- openlp/plugins/bibles/forms/bibleimportform.py	2011-02-10 21:07:28 +0000
+++ openlp/plugins/bibles/forms/bibleimportform.py	2011-02-11 22:36:52 +0000
@@ -35,7 +35,7 @@
 
 from openlp.core.lib import Receiver, translate
 from openlp.core.lib.db import delete_database
-from openlp.core.lib.ui import critical_error_message_box
+from openlp.core.lib.ui import UiStrings, critical_error_message_box
 from openlp.core.ui.wizard import OpenLPWizard
 from openlp.core.utils import AppLocation, string_is_unicode
 from openlp.plugins.bibles.lib.manager import BibleFormat
@@ -468,9 +468,7 @@
         elif self.currentPage() == self.selectPage:
             if self.field(u'source_format').toInt()[0] == BibleFormat.OSIS:
                 if not self.field(u'osis_location').toString():
-                    critical_error_message_box(
-                        translate('BiblesPlugin.ImportWizardForm',
-                        'Invalid Bible Location'),
+                    critical_error_message_box(UiStrings.NFSs,
                         translate('BiblesPlugin.ImportWizardForm',
                         'You need to specify a file to import your '
                         'Bible from.'))
@@ -478,8 +476,7 @@
                     return False
             elif self.field(u'source_format').toInt()[0] == BibleFormat.CSV:
                 if not self.field(u'csv_testamentsfile').toString():
-                    answer = critical_error_message_box(translate(
-                        'BiblesPlugin.ImportWizardForm', 'No Testaments File'),
+                    answer = critical_error_message_box(UiStrings.NFSs,
                         translate('BiblesPlugin.ImportWizardForm',
                         'You have not specified a testaments file. Do you '
                         'want to proceed with the import?'), question=True)
@@ -487,18 +484,14 @@
                         self.csvTestamentsEdit.setFocus()
                         return False
                 elif not self.field(u'csv_booksfile').toString():
-                    critical_error_message_box(
-                        translate('BiblesPlugin.ImportWizardForm',
-                        'Invalid Books File'),
+                    critical_error_message_box(UiStrings.NFSs,
                         translate('BiblesPlugin.ImportWizardForm',
                         'You need to specify a file with books of '
                         'the Bible to use in the import.'))
                     self.csvBooksEdit.setFocus()
                     return False
                 elif not self.field(u'csv_versefile').toString():
-                    critical_error_message_box(
-                        translate('BiblesPlugin.ImportWizardForm',
-                        'Invalid Verse File'),
+                    critical_error_message_box(UiStrings.NFSs,
                         translate('BiblesPlugin.ImportWizardForm',
                         'You need to specify a file of Bible '
                         'verses to import.'))
@@ -507,9 +500,7 @@
             elif self.field(u'source_format').toInt()[0] == \
                 BibleFormat.OpenSong:
                 if not self.field(u'opensong_file').toString():
-                    critical_error_message_box(
-                        translate('BiblesPlugin.ImportWizardForm',
-                        'Invalid OpenSong Bible'),
+                    critical_error_message_box(UiStrings.NFSs,
                         translate('BiblesPlugin.ImportWizardForm',
                         'You need to specify an OpenSong Bible '
                         'file to import.'))
@@ -517,9 +508,7 @@
                     return False
             elif self.field(u'source_format').toInt()[0] == BibleFormat.OpenLP1:
                 if not self.field(u'openlp1_location').toString():
-                    critical_error_message_box(
-                        translate('BiblesPlugin.ImportWizardForm',
-                        'Invalid Bible Location'),
+                    critical_error_message_box(UiStrings.NFSs,
                         translate('BiblesPlugin.ImportWizardForm',
                         'You need to specify a file to import your '
                         'Bible from.'))
@@ -531,17 +520,13 @@
             license_copyright = \
                 unicode(self.field(u'license_copyright').toString())
             if not license_version:
-                critical_error_message_box(
-                    translate('BiblesPlugin.ImportWizardForm',
-                    'Empty Version Name'),
+                critical_error_message_box(UiStrings.EmptyField,
                     translate('BiblesPlugin.ImportWizardForm',
                     'You need to specify a version name for your Bible.'))
                 self.versionNameEdit.setFocus()
                 return False
             elif not license_copyright:
-                critical_error_message_box(
-                    translate('BiblesPlugin.ImportWizardForm',
-                    'Empty Copyright'),
+                critical_error_message_box(UiStrings.EmptyField,
                     translate('BiblesPlugin.ImportWizardForm',
                     'You need to set a copyright for your Bible. '
                     'Bibles in the Public Domain need to be marked as such.'))

=== modified file 'openlp/plugins/custom/customplugin.py'
--- openlp/plugins/custom/customplugin.py	2011-02-11 04:04:05 +0000
+++ openlp/plugins/custom/customplugin.py	2011-02-11 22:36:52 +0000
@@ -52,7 +52,7 @@
             CustomMediaItem, CustomTab)
         self.weight = -5
         self.manager = Manager(u'custom', init_schema)
-        self.edit_custom_form = EditCustomForm(self.manager)
+        self.edit_custom_form = EditCustomForm(self)
         self.icon_path = u':/plugins/plugin_custom.png'
         self.icon = build_icon(self.icon_path)
 

=== modified file 'openlp/plugins/custom/forms/editcustomdialog.py'
--- openlp/plugins/custom/forms/editcustomdialog.py	2011-02-10 00:36:00 +0000
+++ openlp/plugins/custom/forms/editcustomdialog.py	2011-02-11 22:36:52 +0000
@@ -26,7 +26,7 @@
 
 from PyQt4 import QtCore, QtGui
 
-from openlp.core.lib import build_icon, translate
+from openlp.core.lib import StringContent, build_icon, translate
 from openlp.core.lib.ui import UiStrings, create_accept_reject_button_box, \
     create_delete_push_button, create_up_down_push_button_set
 
@@ -66,7 +66,9 @@
         self.editAllButton = QtGui.QPushButton(customEditDialog)
         self.editAllButton.setObjectName(u'editAllButton')
         self.buttonLayout.addWidget(self.editAllButton)
-        self.deleteButton = create_delete_push_button(customEditDialog)
+        self.deleteButton = create_delete_push_button(customEditDialog,
+            customEditDialog.parent.getString(
+            StringContent.Name)[u'singular'].toLower())
         self.deleteButton.setEnabled(False)
         self.buttonLayout.addWidget(self.deleteButton)
         self.buttonLayout.addStretch()

=== modified file 'openlp/plugins/custom/forms/editcustomform.py'
--- openlp/plugins/custom/forms/editcustomform.py	2011-02-04 19:27:25 +0000
+++ openlp/plugins/custom/forms/editcustomform.py	2011-02-11 22:36:52 +0000
@@ -42,14 +42,15 @@
     Class documentation goes here.
     """
     log.info(u'Custom Editor loaded')
-    def __init__(self, manager, parent=None):
+    def __init__(self, parent):
         """
         Constructor
         """
-        QtGui.QDialog.__init__(self, parent)
+        QtGui.QDialog.__init__(self)
+        self.parent = parent
+        self.manager = self.parent.manager
         self.setupUi(self)
         # Create other objects and forms.
-        self.manager = manager
         self.editSlideForm = EditCustomSlideForm(self)
         # Connecting signals and slots
         QtCore.QObject.connect(self.previewButton,

=== modified file 'openlp/plugins/songs/forms/authorsdialog.py'
--- openlp/plugins/songs/forms/authorsdialog.py	2011-02-10 00:36:00 +0000
+++ openlp/plugins/songs/forms/authorsdialog.py	2011-02-11 22:36:52 +0000
@@ -28,6 +28,7 @@
 
 from openlp.core.lib import translate
 from openlp.core.lib.ui import create_accept_reject_button_box
+from openlp.plugins.songs.lib.ui import SongStrings
 
 class Ui_AuthorsDialog(object):
     def setupUi(self, authorsDialog):
@@ -64,7 +65,7 @@
 
     def retranslateUi(self, authorsDialog):
         authorsDialog.setWindowTitle(
-            translate('SongsPlugin.AuthorsForm', 'Author Maintenance'))
+            SongStrings.TypeMaintenance % SongStrings.Author)
         self.displayLabel.setText(
             translate('SongsPlugin.AuthorsForm', 'Display name:'))
         self.firstNameLabel.setText(

=== modified file 'openlp/plugins/songs/forms/editsongdialog.py'
--- openlp/plugins/songs/forms/editsongdialog.py	2011-02-10 00:36:00 +0000
+++ openlp/plugins/songs/forms/editsongdialog.py	2011-02-11 22:36:52 +0000
@@ -28,6 +28,7 @@
 
 from openlp.core.lib import build_icon, translate
 from openlp.core.lib.ui import UiStrings, create_accept_reject_button_box
+from openlp.plugins.songs.lib.ui import SongStrings
 
 class Ui_EditSongDialog(object):
     def setupUi(self, editSongDialog):
@@ -265,21 +266,19 @@
         self.songTabWidget.setTabText(
             self.songTabWidget.indexOf(self.lyricsTab),
             translate('SongsPlugin.EditSongForm', 'Title && Lyrics'))
-        self.authorsGroupBox.setTitle(UiStrings.Authors)
+        self.authorsGroupBox.setTitle(SongStrings.Authors)
         self.authorAddButton.setText(
             translate('SongsPlugin.EditSongForm', '&Add to Song'))
         self.authorRemoveButton.setText(
             translate('SongsPlugin.EditSongForm', '&Remove'))
         self.maintenanceButton.setText(translate('SongsPlugin.EditSongForm',
             '&Manage Authors, Topics, Song Books'))
-        self.topicsGroupBox.setTitle(
-            translate('SongsPlugin.EditSongForm', 'Topic'))
+        self.topicsGroupBox.setTitle(SongStrings.Topic)
         self.topicAddButton.setText(
             translate('SongsPlugin.EditSongForm', 'A&dd to Song'))
         self.topicRemoveButton.setText(
             translate('SongsPlugin.EditSongForm', 'R&emove'))
-        self.songBookGroupBox.setTitle(
-            translate('SongsPlugin.EditSongForm', 'Song Book'))
+        self.songBookGroupBox.setTitle(SongStrings.SongBook)
         self.songBookNameLabel.setText(translate('SongsPlugin.EditSongForm',
             'Book:'))
         self.songBookNumberLabel.setText(translate('SongsPlugin.EditSongForm',

=== modified file 'openlp/plugins/songs/forms/songbookdialog.py'
--- openlp/plugins/songs/forms/songbookdialog.py	2011-02-10 00:36:00 +0000
+++ openlp/plugins/songs/forms/songbookdialog.py	2011-02-11 22:36:52 +0000
@@ -28,6 +28,7 @@
 
 from openlp.core.lib import translate
 from openlp.core.lib.ui import create_accept_reject_button_box
+from openlp.plugins.songs.lib.ui import SongStrings
 
 class Ui_SongBookDialog(object):
     def setupUi(self, songBookDialog):
@@ -58,7 +59,7 @@
 
     def retranslateUi(self, songBookDialog):
         songBookDialog.setWindowTitle(
-            translate('SongsPlugin.SongBookForm', 'Song Book Maintenance'))
+            SongStrings.TypeMaintenance % SongStrings.SongBook)
         self.nameLabel.setText(translate('SongsPlugin.SongBookForm', '&Name:'))
         self.publisherLabel.setText(
             translate('SongsPlugin.SongBookForm', '&Publisher:'))

=== modified file 'openlp/plugins/songs/forms/songimportform.py'
--- openlp/plugins/songs/forms/songimportform.py	2011-02-10 19:37:02 +0000
+++ openlp/plugins/songs/forms/songimportform.py	2011-02-11 22:36:52 +0000
@@ -330,9 +330,7 @@
             source_format = self.formatComboBox.currentIndex()
             if source_format == SongFormat.OpenLP2:
                 if self.openLP2FilenameEdit.text().isEmpty():
-                    critical_error_message_box(
-                        translate('SongsPlugin.ImportWizardForm',
-                        'No OpenLP 2.0 Song Database Selected'),
+                    critical_error_message_box(UiStrings.NFSs,
                         translate('SongsPlugin.ImportWizardForm',
                         'You need to select an OpenLP 2.0 song database '
                         'file to import from.'))
@@ -340,9 +338,7 @@
                     return False
             elif source_format == SongFormat.OpenLP1:
                 if self.openLP1FilenameEdit.text().isEmpty():
-                    critical_error_message_box(
-                        translate('SongsPlugin.ImportWizardForm',
-                        'No openlp.org 1.x Song Database Selected'),
+                    critical_error_message_box(UiStrings.NFSs,
                         translate('SongsPlugin.ImportWizardForm',
                         'You need to select an openlp.org 1.x song '
                         'database file to import from.'))
@@ -350,9 +346,7 @@
                     return False
             elif source_format == SongFormat.OpenLyrics:
                 if self.openLyricsFileListWidget.count() == 0:
-                    critical_error_message_box(
-                        translate('SongsPlugin.ImportWizardForm',
-                        'No OpenLyrics Files Selected'),
+                    critical_error_message_box(UiStrings.NFSp,
                         translate('SongsPlugin.ImportWizardForm',
                         'You need to add at least one OpenLyrics '
                         'song file to import from.'))
@@ -360,9 +354,7 @@
                     return False
             elif source_format == SongFormat.OpenSong:
                 if self.openSongFileListWidget.count() == 0:
-                    critical_error_message_box(
-                        translate('SongsPlugin.ImportWizardForm',
-                        'No OpenSong Files Selected'),
+                    critical_error_message_box(UiStrings.NFSp,
                         translate('SongsPlugin.ImportWizardForm',
                         'You need to add at least one OpenSong '
                         'song file to import from.'))
@@ -370,9 +362,7 @@
                     return False
             elif source_format == SongFormat.WordsOfWorship:
                 if self.wordsOfWorshipFileListWidget.count() == 0:
-                    critical_error_message_box(
-                        translate('SongsPlugin.ImportWizardForm',
-                        'No Words of Worship Files Selected'),
+                    critical_error_message_box(UiStrings.NFSp,
                         translate('SongsPlugin.ImportWizardForm',
                         'You need to add at least one Words of Worship '
                         'file to import from.'))
@@ -380,9 +370,7 @@
                     return False
             elif source_format == SongFormat.CCLI:
                 if self.ccliFileListWidget.count() == 0:
-                    critical_error_message_box(
-                        translate('SongsPlugin.ImportWizardForm',
-                        'No CCLI Files Selected'),
+                    critical_error_message_box(UiStrings.NFSp,
                         translate('SongsPlugin.ImportWizardForm',
                         'You need to add at least one CCLI file '
                         'to import from.'))
@@ -390,9 +378,7 @@
                     return False
             elif source_format == SongFormat.SongsOfFellowship:
                 if self.songsOfFellowshipFileListWidget.count() == 0:
-                    critical_error_message_box(
-                        translate('SongsPlugin.ImportWizardForm',
-                        'No Songs of Fellowship File Selected'),
+                    critical_error_message_box(UiStrings.NFSp,
                         translate('SongsPlugin.ImportWizardForm',
                         'You need to add at least one Songs of Fellowship '
                         'file to import from.'))
@@ -400,9 +386,7 @@
                     return False
             elif source_format == SongFormat.Generic:
                 if self.genericFileListWidget.count() == 0:
-                    critical_error_message_box(
-                        translate('SongsPlugin.ImportWizardForm',
-                        'No Document/Presentation Selected'),
+                    critical_error_message_box(UiStrings.NFSp,
                         translate('SongsPlugin.ImportWizardForm',
                         'You need to add at least one document or '
                         'presentation file to import from.'))
@@ -410,9 +394,7 @@
                     return False
             elif source_format == SongFormat.EasiSlides:
                 if self.easiSlidesFilenameEdit.text().isEmpty():
-                    critical_error_message_box(
-                        translate('SongsPlugin.ImportWizardForm',
-                        'No Easislides Songs file selected'),
+                    critical_error_message_box(UiStrings.NFSp,
                         translate('SongsPlugin.ImportWizardForm',
                         'You need to select an xml song file exported from '
                         'EasiSlides, to import from.'))
@@ -420,9 +402,7 @@
                     return False
             elif source_format == SongFormat.EasyWorship:
                 if self.ewFilenameEdit.text().isEmpty():
-                    critical_error_message_box(
-                        translate('SongsPlugin.ImportWizardForm',
-                        'No EasyWorship Song Database Selected'),
+                    critical_error_message_box(UiStrings.NFSs,
                         translate('SongsPlugin.ImportWizardForm',
                         'You need to select an EasyWorship song database '
                         'file to import from.'))
@@ -430,9 +410,7 @@
                     return False
             elif source_format == SongFormat.SongBeamer:
                 if self.songBeamerFileListWidget.count() == 0:
-                    critical_error_message_box(
-                        translate('SongsPlugin.ImportWizardForm',
-                        'No SongBeamer File Selected'),
+                    critical_error_message_box(UiStrings.NFSp,
                         translate('SongsPlugin.ImportWizardForm',
                         'You need to add at least one SongBeamer '
                         'file to import from.'))
@@ -585,7 +563,7 @@
             'Select Songs of Fellowship Files'),
             self.songsOfFellowshipFileListWidget, u'%s (*.rtf)'
             % translate('SongsPlugin.ImportWizardForm',
-            'Songs Of Felloship Song Files')
+            'Songs Of Fellowship Song Files')
         )
 
     def onSongsOfFellowshipRemoveButtonClicked(self):

=== modified file 'openlp/plugins/songs/forms/songmaintenancedialog.py'
--- openlp/plugins/songs/forms/songmaintenancedialog.py	2011-02-09 05:04:12 +0000
+++ openlp/plugins/songs/forms/songmaintenancedialog.py	2011-02-11 22:36:52 +0000
@@ -26,8 +26,9 @@
 
 from PyQt4 import QtCore, QtGui
 
-from openlp.core.lib import build_icon, translate
+from openlp.core.lib import build_icon
 from openlp.core.lib.ui import UiStrings
+from openlp.plugins.songs.lib.ui import SongStrings
 
 class Ui_SongMaintenanceDialog(object):
     def setupUi(self, songMaintenanceDialog):
@@ -145,13 +146,10 @@
 
     def retranslateUi(self, songMaintenanceDialog):
         songMaintenanceDialog.setWindowTitle(
-            translate('SongsPlugin.SongMaintenanceForm', 'Song Maintenance'))
-        authorsString = UiStrings.Authors
-        topicsString = translate('SongsPlugin.SongMaintenanceForm', 'Topics')
-        booksString = translate('SongsPlugin.SongMaintenanceForm', 'Song Books')
-        self.listItemAuthors.setText(authorsString)
-        self.listItemTopics.setText(topicsString)
-        self.listItemBooks.setText(booksString)
+            SongStrings.TypeMaintenance % SongStrings.Song)
+        self.listItemAuthors.setText(SongStrings.Authors)
+        self.listItemTopics.setText(SongStrings.Topics)
+        self.listItemBooks.setText(SongStrings.SongBooks)
         self.authorsAddButton.setText(UiStrings.Add)
         self.authorsEditButton.setText(UiStrings.Edit)
         self.authorsDeleteButton.setText(UiStrings.Delete)
@@ -161,8 +159,8 @@
         self.booksAddButton.setText(UiStrings.Add)
         self.booksEditButton.setText(UiStrings.Edit)
         self.booksDeleteButton.setText(UiStrings.Delete)
-        typeListWidth = max(self.fontMetrics().width(authorsString),
-            self.fontMetrics().width(topicsString),
-            self.fontMetrics().width(booksString))
+        typeListWidth = max(self.fontMetrics().width(SongStrings.Authors),
+            self.fontMetrics().width(SongStrings.Topics),
+            self.fontMetrics().width(SongStrings.SongBooks))
         self.typeListWidget.setFixedWidth(typeListWidth +
             self.typeListWidget.iconSize().width() + 32)

=== modified file 'openlp/plugins/songs/forms/topicsdialog.py'
--- openlp/plugins/songs/forms/topicsdialog.py	2011-02-10 00:36:00 +0000
+++ openlp/plugins/songs/forms/topicsdialog.py	2011-02-11 22:36:52 +0000
@@ -28,6 +28,7 @@
 
 from openlp.core.lib import translate
 from openlp.core.lib.ui import create_accept_reject_button_box
+from openlp.plugins.songs.lib.ui import SongStrings
 
 class Ui_TopicsDialog(object):
     def setupUi(self, topicsDialog):
@@ -52,6 +53,6 @@
 
     def retranslateUi(self, topicsDialog):
         topicsDialog.setWindowTitle(
-            translate('SongsPlugin.TopicsForm', 'Topic Maintenance'))
+            SongStrings.TypeMaintenance % SongStrings.Topic)
         self.nameLabel.setText(
             translate('SongsPlugin.TopicsForm', 'Topic name:'))

=== modified file 'openlp/plugins/songs/lib/mediaitem.py'
--- openlp/plugins/songs/lib/mediaitem.py	2011-02-10 18:38:40 +0000
+++ openlp/plugins/songs/lib/mediaitem.py	2011-02-11 22:36:52 +0000
@@ -38,6 +38,7 @@
     SongImportForm, SongExportForm
 from openlp.plugins.songs.lib import OpenLyrics, SongXML
 from openlp.plugins.songs.lib.db import Author, Song
+from openlp.plugins.songs.lib.ui import SongStrings
 from openlp.core.lib.searchedit import SearchEdit
 
 log = logging.getLogger(__name__)
@@ -129,7 +130,7 @@
         self.searchTextButton.setText(
             translate('SongsPlugin.MediaItem', 'Search'))
         self.maintenanceAction.setText(
-            translate('SongsPlugin.MediaItem', 'Song Maintenance'))
+            SongStrings.TypeMaintenance % SongStrings.Song)
         self.maintenanceAction.setToolTip(translate('SongsPlugin.MediaItem',
             'Maintain the lists of authors, topics and books'))
 
@@ -141,7 +142,7 @@
                 translate('SongsPlugin.MediaItem', 'Titles')),
             (3, u':/songs/song_search_lyrics.png',
                 translate('SongsPlugin.MediaItem', 'Lyrics')),
-            (4, u':/songs/song_search_author.png', UiStrings.Authors),
+            (4, u':/songs/song_search_author.png', SongStrings.Authors),
             (5, u':/slides/slide_theme.png', UiStrings.Themes)
         ])
         self.configUpdated()

=== added file 'openlp/plugins/songs/lib/ui.py'
--- openlp/plugins/songs/lib/ui.py	1970-01-01 00:00:00 +0000
+++ openlp/plugins/songs/lib/ui.py	2011-02-11 22:36:52 +0000
@@ -0,0 +1,43 @@
+# -*- coding: utf-8 -*-
+# vim: autoindent shiftwidth=4 expandtab textwidth=80 tabstop=4 softtabstop=4
+
+###############################################################################
+# OpenLP - Open Source Lyrics Projection                                      #
+# --------------------------------------------------------------------------- #
+# Copyright (c) 2008-2011 Raoul Snyman                                        #
+# Portions copyright (c) 2008-2011 Tim Bentley, Jonathan Corwin, Michael      #
+# Gorven, Scott Guerrieri, Meinert Jordan, Andreas Preikschat, Christian      #
+# Richter, Philip Ridout, Maikel Stuivenberg, Martin Thompson, Jon Tibble,    #
+# Carsten Tinggaard, Frode Woldsund                                           #
+# --------------------------------------------------------------------------- #
+# 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  #
+# Software Foundation; version 2 of the License.                              #
+#                                                                             #
+# This program is distributed in the hope that it will be useful, but WITHOUT #
+# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or       #
+# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for    #
+# more details.                                                               #
+#                                                                             #
+# You should have received a copy of the GNU General Public License along     #
+# with this program; if not, write to the Free Software Foundation, Inc., 59  #
+# Temple Place, Suite 330, Boston, MA 02111-1307 USA                          #
+###############################################################################
+"""
+The :mod:`openlp.plugins.songs.lib.ui` module provides standard UI components
+for the songs plugin.
+"""
+from openlp.core.lib import translate
+
+class SongStrings(object):
+    """
+    Provide standard strings for use throughout the songs plugin.
+    """
+    # These strings should need a good reason to be retranslated elsewhere.
+    Author = translate('OpenLP.Ui', 'Author', 'Singular')
+    Authors = translate('OpenLP.Ui', 'Authors', 'Plural')
+    SongBook = translate('OpenLP.Ui', 'Song Book', 'Singular')
+    SongBooks = translate('OpenLP.Ui', 'Song Books', 'Plural')
+    Topic = translate('OpenLP.Ui', 'Topic', 'Singular')
+    Topics = translate('OpenLP.Ui', 'Topics', 'Plural')
+    TypeMaintenance = unicode(translate('OpenLP.Ui', '%s Maintenance'))