From: Moritz Venn Date: Mon, 5 Oct 2009 13:51:09 +0000 (+0000) Subject: button -> statictext, X-Git-Url: http://code.vuplus.com/gitweb/?p=vuplus_dvbapp-plugin;a=commitdiff_plain;h=c55f760d77f0b2d95508b255d02156b15c52d009 button -> statictext, center screen, move buttons to top, make title translatable --- diff --git a/tageditor/src/plugin.py b/tageditor/src/plugin.py index 717d106..53e5514 100644 --- a/tageditor/src/plugin.py +++ b/tageditor/src/plugin.py @@ -8,7 +8,7 @@ from Screens.ChoiceBox import ChoiceBox from Screens.MessageBox import MessageBox from Components.config import config from Components.ActionMap import ActionMap -from Components.Button import Button +from Components.Sources.StaticText import StaticText from Components.SelectionList import SelectionList from enigma import eServiceReference, eServiceCenter, iServiceInformation from os import path as os_path @@ -26,26 +26,26 @@ def Plugins(**kwargs): class TagEditor(Screen): skin = """ - - - - - - - - - - + + + + + + + + + + """ def __init__(self, session, tags, txt = None, args = 0, parent = None): Screen.__init__(self, session, parent = parent) # Initialize Buttons - self["key_red"] = Button(_("Cancel")) - self["key_green"] = Button(_("OK")) - self["key_yellow"] = Button(_("New")) - self["key_blue"] = Button(_("Load")) + self["key_red"] = StaticText(_("Cancel")) + self["key_green"] = StaticText(_("OK")) + self["key_yellow"] = StaticText(_("New")) + self["key_blue"] = StaticText(_("Load")) self["list"] = SelectionList() @@ -70,6 +70,11 @@ class TagEditor(Screen): "menu": self.showMenu }, -1) + self.onLayoutFinish.append(self.setCustomTitle) + + def setCustomTitle(self): + self.setTitle(_("Edit Tags")) + def addCustom(self): self.session.openWithCallback( self.addCustomCallback,