From 116c5b030f7a0d1e616d96150bb738e493233c46 Mon Sep 17 00:00:00 2001 From: Tim Bentley Date: Thu, 22 Nov 2012 22:02:40 +0000 Subject: [PATCH] Fix media language Automatic --- openlp/core/lib/ui.py | 1 + openlp/core/ui/media/mediacontroller.py | 4 ++-- openlp/plugins/media/lib/mediaitem.py | 3 +-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/openlp/core/lib/ui.py b/openlp/core/lib/ui.py index c96472fe3..beaaf15cc 100644 --- a/openlp/core/lib/ui.py +++ b/openlp/core/lib/ui.py @@ -61,6 +61,7 @@ class UiStrings(object): self.Add = translate('OpenLP.Ui', '&Add') self.Advanced = translate('OpenLP.Ui', 'Advanced') self.AllFiles = translate('OpenLP.Ui', 'All Files') + self.Automatic = translate('OpenLP.Ui', 'Automatic') self.Bottom = translate('OpenLP.Ui', 'Bottom') self.Browse = translate('OpenLP.Ui', 'Browse...') self.Cancel = translate('OpenLP.Ui', 'Cancel') diff --git a/openlp/core/ui/media/mediacontroller.py b/openlp/core/ui/media/mediacontroller.py index d99edf580..197d3dfc7 100644 --- a/openlp/core/ui/media/mediacontroller.py +++ b/openlp/core/ui/media/mediacontroller.py @@ -34,7 +34,7 @@ from PyQt4 import QtCore, QtGui from openlp.core.lib import OpenLPToolbar, Receiver, translate from openlp.core.lib.settings import Settings -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.media import MediaState, MediaInfo, MediaType, \ get_media_players, set_media_players from openlp.core.ui.media.mediaplayer import MediaPlayer @@ -479,7 +479,7 @@ class MediaController(object): The ServiceItem containing the details to be played. """ usedPlayers = get_media_players()[0] - if serviceItem.title != u'Automatic': + if serviceItem.title != UiStrings().Automatic: usedPlayers = [serviceItem.title.lower()] if controller.media_info.file_info.isFile(): suffix = u'*.%s' % \ diff --git a/openlp/plugins/media/lib/mediaitem.py b/openlp/plugins/media/lib/mediaitem.py index b7c6e89ba..daddefc17 100644 --- a/openlp/plugins/media/lib/mediaitem.py +++ b/openlp/plugins/media/lib/mediaitem.py @@ -95,8 +95,7 @@ class MediaMediaItem(MediaManagerItem): self.replaceAction.setToolTip(UiStrings().ReplaceLiveBG) self.resetAction.setText(UiStrings().ResetBG) self.resetAction.setToolTip(UiStrings().ResetLiveBG) - self.automatic = translate('MediaPlugin.MediaItem', - 'Automatic') + self.automatic = UiStrings().Automatic self.displayTypeLabel.setText( translate('MediaPlugin.MediaItem', 'Use Player:')) self.rebuild_players()