X-Git-Url: https://git.cweiske.de/enigma2.git/blobdiff_plain/c2217d20163573e3a062463bfe0522e4f70b1fa4..ca13d7906607bb7be40e7695e36054b8b86c8529:/lib/python/Plugins/Extensions/DVDBurn/DVDProject.py diff --git a/lib/python/Plugins/Extensions/DVDBurn/DVDProject.py b/lib/python/Plugins/Extensions/DVDBurn/DVDProject.py index 660234f2..83672460 100644 --- a/lib/python/Plugins/Extensions/DVDBurn/DVDProject.py +++ b/lib/python/Plugins/Extensions/DVDBurn/DVDProject.py @@ -18,6 +18,8 @@ class ConfigFilename(ConfigText): return ("mtext"[1-selected:], filename, mark) class DVDProject: + MAX_SL = 4480 + MAX_DL = 8150 def __init__(self): self.titles = [ ] self.target = None @@ -113,7 +115,7 @@ class DVDProject: if project.nodeType == xml.dom.minidom.Element.nodeType: if project.tagName == 'settings': i = 0 - if project.attributes.length < len(self.settings.dict()): + if project.attributes.length < len(self.settings.dict())-1: self.error = "project attributes missing" raise AttributeError while i < project.attributes.length: @@ -140,6 +142,14 @@ class DVDProject: return False return True + def getSize(self): + totalsize = 0 + for title in self.titles: + totalsize += title.estimatedDiskspace + return totalsize + + size = property(getSize) + class MenuTemplate(DVDProject): def __init__(self): self.settings = ConfigSubsection() @@ -175,6 +185,8 @@ class MenuTemplate(DVDProject): self.settings.thumb_size = ConfigSequence(seperator = ',', default = [200,158], limits = [(0,576),(-1,720)]) self.settings.thumb_border = ConfigInteger(default = 2, limits = (0, 20)) self.filekeys = ["menubg", "menuaudio", "fontface_headline", "fontface_title", "fontface_subtitle"] + from TitleProperties import languageChoices + self.settings.menulang = ConfigSelection(choices = languageChoices.choices, default=languageChoices.choices[1][0]) def loadTemplate(self, filename): ret = DVDProject.loadProject(self, filename)