From d538a32f491a22a83cdc4a081133bf93222d7535 Mon Sep 17 00:00:00 2001 From: Tim Bentley Date: Sat, 24 Nov 2012 08:01:10 +0000 Subject: [PATCH] String clean ups --- openlp/core/lib/ui.py | 2 ++ openlp/core/ui/media/playertab.py | 6 ++---- openlp/plugins/images/lib/imagetab.py | 7 +++---- 3 files changed, 7 insertions(+), 8 deletions(-) diff --git a/openlp/core/lib/ui.py b/openlp/core/lib/ui.py index beaaf15cc..0880746d3 100644 --- a/openlp/core/lib/ui.py +++ b/openlp/core/lib/ui.py @@ -62,6 +62,7 @@ class UiStrings(object): self.Advanced = translate('OpenLP.Ui', 'Advanced') self.AllFiles = translate('OpenLP.Ui', 'All Files') self.Automatic = translate('OpenLP.Ui', 'Automatic') + self.BackgroundColor = translate('OpenLP.Ui', 'Background Color') self.Bottom = translate('OpenLP.Ui', 'Bottom') self.Browse = translate('OpenLP.Ui', 'Browse...') self.Cancel = translate('OpenLP.Ui', 'Cancel') @@ -70,6 +71,7 @@ class UiStrings(object): self.ConfirmDelete = translate('OpenLP.Ui', 'Confirm Delete') self.Continuous = translate('OpenLP.Ui', 'Continuous') self.Default = unicode(translate('OpenLP.Ui', 'Default')) + self.DefaultColor = translate('OpenLP.Ui', 'Default Color:') self.Delete = translate('OpenLP.Ui', '&Delete') self.DisplayStyle = translate('OpenLP.Ui', 'Display style:') self.Duplicate = translate('OpenLP.Ui', 'Duplicate Error') diff --git a/openlp/core/ui/media/playertab.py b/openlp/core/ui/media/playertab.py index 9a1275555..2bf2d4458 100644 --- a/openlp/core/ui/media/playertab.py +++ b/openlp/core/ui/media/playertab.py @@ -129,10 +129,8 @@ class PlayerTab(SettingsTab): translate('OpenLP.PlayerTab', 'Available Media Players')) self.playerOrderGroupBox.setTitle( translate('OpenLP.PlayerTab', 'Player Search Order')) - self.bgColorGroupBox.setTitle( - translate('ImagesPlugin.ImageTab', 'Background Color')) - self.backgroundColorLabel.setText( - translate('ImagesPlugin.ImageTab', 'Default Color:')) + self.bgColorGroupBox.setTitle(UiStrings().BackgroundColor) + self.backgroundColorLabel.setText(UiStrings().DefaultColor) self.informationLabel.setText( translate('OpenLP.PlayerTab', 'Visible background for videos ' 'with aspect ratio different to screen.')) diff --git a/openlp/plugins/images/lib/imagetab.py b/openlp/plugins/images/lib/imagetab.py index dfb294e1c..5bf957aa8 100644 --- a/openlp/plugins/images/lib/imagetab.py +++ b/openlp/plugins/images/lib/imagetab.py @@ -31,6 +31,7 @@ from PyQt4 import QtCore, QtGui from openlp.core.lib import SettingsTab, translate, Receiver from openlp.core.lib.settings import Settings +from openlp.core.lib.ui import UiStrings class ImageTab(SettingsTab): """ @@ -68,10 +69,8 @@ class ImageTab(SettingsTab): QtCore.SIGNAL(u'clicked()'), self.onbackgroundColorButtonClicked) def retranslateUi(self): - self.bgColorGroupBox.setTitle( - translate('ImagesPlugin.ImageTab', 'Background Color')) - self.backgroundColorLabel.setText( - translate('ImagesPlugin.ImageTab', 'Default Color:')) + self.bgColorGroupBox.setTitle(UiStrings().BackgroundColor) + self.backgroundColorLabel.setText(UiStrings().DefaultColor) self.informationLabel.setText( translate('ImagesPlugin.ImageTab', 'Visible background for images ' 'with aspect ratio different to screen.'))