From 65f1464c0852068d8a60e07e02da6a892d45578b Mon Sep 17 00:00:00 2001 From: Fraxinas Date: Tue, 17 Nov 2009 16:08:15 +0100 Subject: for all non-ts files, display error message when trying to burn to dvd --- lib/python/Plugins/Extensions/DVDBurn/TitleList.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'lib/python') diff --git a/lib/python/Plugins/Extensions/DVDBurn/TitleList.py b/lib/python/Plugins/Extensions/DVDBurn/TitleList.py index 928a8b82..bb40cc30 100755 --- a/lib/python/Plugins/Extensions/DVDBurn/TitleList.py +++ b/lib/python/Plugins/Extensions/DVDBurn/TitleList.py @@ -188,6 +188,9 @@ class TitleList(Screen, HelpableScreen): def selectedSource(self, source): if source is None: return None + if not source.getPath().endswith(".ts"): + self.session.open(MessageBox,text = _("You can only burn Dreambox recordings!"), type = MessageBox.TYPE_ERROR) + return None t = self.project.addService(source) try: editor = source.edit -- cgit v1.2.3 From ed2cbe10c1c5dae3763802268c840d0328482180 Mon Sep 17 00:00:00 2001 From: Fraxinas Date: Wed, 25 Nov 2009 09:49:38 +0100 Subject: DVDBurn Plugin: prevent "English" from showing up twice in language selection --- lib/python/Plugins/Extensions/DVDBurn/TitleProperties.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'lib/python') diff --git a/lib/python/Plugins/Extensions/DVDBurn/TitleProperties.py b/lib/python/Plugins/Extensions/DVDBurn/TitleProperties.py index 11601cc3..c3f78d4a 100755 --- a/lib/python/Plugins/Extensions/DVDBurn/TitleProperties.py +++ b/lib/python/Plugins/Extensions/DVDBurn/TitleProperties.py @@ -164,7 +164,8 @@ class LanguageChoices(): self.choices.sort() self.choices.insert(0,("nolang", ("unspecified"))) self.choices.insert(1,(syslang, self.langdict[syslang])) - self.choices.insert(2,("en", self.langdict["en"])) + if syslang != "en": + self.choices.insert(2,("en", self.langdict["en"])) def getLanguage(self, DVB_lang): DVB_lang = DVB_lang.lower() -- cgit v1.2.3 From aafcdf90d03df876684e7deea2ba40152f9aef1a Mon Sep 17 00:00:00 2001 From: Fraxinas Date: Wed, 25 Nov 2009 12:34:58 +0100 Subject: DVDBurn: switch TiteList to templatedmulticontentlist, allow skinning and display extra title information --- lib/python/Plugins/Extensions/DVDBurn/TitleList.py | 28 +++++++++++++++------- 1 file changed, 19 insertions(+), 9 deletions(-) (limited to 'lib/python') diff --git a/lib/python/Plugins/Extensions/DVDBurn/TitleList.py b/lib/python/Plugins/Extensions/DVDBurn/TitleList.py index 928a8b82..827476ac 100755 --- a/lib/python/Plugins/Extensions/DVDBurn/TitleList.py +++ b/lib/python/Plugins/Extensions/DVDBurn/TitleList.py @@ -10,7 +10,8 @@ from Components.ActionMap import HelpableActionMap, ActionMap from Components.Sources.List import List from Components.Sources.StaticText import StaticText from Components.Sources.Progress import Progress -from enigma import eListboxPythonMultiContent, gFont, RT_HALIGN_LEFT +from Components.MultiContent import MultiContentEntryText +from enigma import gFont, RT_HALIGN_LEFT, RT_HALIGN_RIGHT from Tools.Directories import resolveFilename, SCOPE_PLUGINS class TitleList(Screen, HelpableScreen): @@ -27,7 +28,17 @@ class TitleList(Screen, HelpableScreen): - + + {"template": [ + MultiContentEntryText(pos = (0, 0), size = (420, 20), font = 0, flags = RT_HALIGN_LEFT, text = 1), # index 1 Title, + MultiContentEntryText(pos = (0, 20), size = (328, 17), font = 1, flags = RT_HALIGN_LEFT, text = 2), # index 2 description, + MultiContentEntryText(pos = (420, 6), size = (120, 20), font = 1, flags = RT_HALIGN_RIGHT, text = 3), # index 3 begin time, + MultiContentEntryText(pos = (328, 20), size = (154, 17), font = 1, flags = RT_HALIGN_RIGHT, text = 4), # index 4 channel, + ], + "fonts": [gFont("Regular", 20), gFont("Regular", 14)], + "itemHeight": 37 + } + @@ -71,7 +82,7 @@ class TitleList(Screen, HelpableScreen): else: self.newProject() - self["titles"] = List(list = [ ], enableWrapAround = True, item_height=30, fonts = [gFont("Regular", 20)]) + self["titles"] = List([]) self.updateTitleList() self.previous_size = 0 self.onLayoutFinish.append(self.layoutFinished) @@ -256,15 +267,14 @@ class TitleList(Screen, HelpableScreen): job = Process.DVDJob(self.project, menupreview=True) job_manager.in_background = False job_manager.AddJob(job) - + def updateTitleList(self): - res = [ ] + list = [ ] for title in self.project.titles: - a = [ title, (eListboxPythonMultiContent.TYPE_TEXT, 0, 5, 500, 25, 0, RT_HALIGN_LEFT, title.properties.menutitle.getValue()) ] - res.append(a) - self["titles"].list = res + list.append((title, title.properties.menutitle.getValue(), title.properties.menusubtitle.getValue(), title.DVBchannel, title.formatDVDmenuText("$D.$M.$Y, $T", 0))) + self["titles"].list = list self.updateSize() - if len(res): + if len(list): self["key_red"].text = _("Remove title") self["key_yellow"].text = _("Title properties") else: -- cgit v1.2.3 From ce98272b7475d1bcd6a8ef78b17f17715ff48589 Mon Sep 17 00:00:00 2001 From: Fraxinas Date: Mon, 30 Nov 2009 10:06:23 +0100 Subject: [DVDBurn] fix bug 333: display movie length in title list --- lib/python/Plugins/Extensions/DVDBurn/TitleList.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'lib/python') diff --git a/lib/python/Plugins/Extensions/DVDBurn/TitleList.py b/lib/python/Plugins/Extensions/DVDBurn/TitleList.py index 827476ac..d22cbe93 100755 --- a/lib/python/Plugins/Extensions/DVDBurn/TitleList.py +++ b/lib/python/Plugins/Extensions/DVDBurn/TitleList.py @@ -34,6 +34,7 @@ class TitleList(Screen, HelpableScreen): MultiContentEntryText(pos = (0, 20), size = (328, 17), font = 1, flags = RT_HALIGN_LEFT, text = 2), # index 2 description, MultiContentEntryText(pos = (420, 6), size = (120, 20), font = 1, flags = RT_HALIGN_RIGHT, text = 3), # index 3 begin time, MultiContentEntryText(pos = (328, 20), size = (154, 17), font = 1, flags = RT_HALIGN_RIGHT, text = 4), # index 4 channel, + MultiContentEntryText(pos = (482, 20), size = (58, 20), font = 1, flags = RT_HALIGN_RIGHT, text = 5), # index 4 channel, ], "fonts": [gFont("Regular", 20), gFont("Regular", 14)], "itemHeight": 37 @@ -271,7 +272,7 @@ class TitleList(Screen, HelpableScreen): def updateTitleList(self): list = [ ] for title in self.project.titles: - list.append((title, title.properties.menutitle.getValue(), title.properties.menusubtitle.getValue(), title.DVBchannel, title.formatDVDmenuText("$D.$M.$Y, $T", 0))) + list.append((title, title.properties.menutitle.getValue(), title.properties.menusubtitle.getValue(), title.DVBchannel, title.formatDVDmenuText("$D.$M.$Y, $T", 0), title.formatDVDmenuText("$l", 0))) self["titles"].list = list self.updateSize() if len(list): -- cgit v1.2.3