ignore applySkin when skinAttributes is None
authorAndreas Monzner <andreas.monzner@multimedia-labs.de>
Thu, 25 Oct 2007 09:33:31 +0000 (09:33 +0000)
committerAndreas Monzner <andreas.monzner@multimedia-labs.de>
Thu, 25 Oct 2007 09:33:31 +0000 (09:33 +0000)
lib/python/Plugins/Extensions/GraphMultiEPG/GraphMultiEpg.py

index 9a8b493576dd7fdce1e6efeed205ee35e4980d40..9040539a61749953b4869d6940bf250010ddcce2 100644 (file)
@@ -49,19 +49,20 @@ class EPGList(HTMLComponent, GUIComponent):
                self.backColorSelected = 0x808080
 
        def applySkin(self, desktop):
-               attribs = [ ]
-               for (attrib, value) in self.skinAttributes:
-                       if attrib == "EntryForegroundColor":
-                               self.foreColor = parseColor(value).argb()
-                       elif attrib == "EntryBorderColor":
-                               self.borderColor = parseColor(value).argb()
-                       elif attrib == "EntryBackgroundColor":
-                               self.backColor = parseColor(value).argb()
-                       elif attrib == "EntryBackgroundColorSelected":
-                               self.backColorSelected = parseColor(value).argb()
-                       else:
-                               attribs.append((attrib,value))
-               self.skinAttributes = attribs
+               if self.skinAttributes is not None:
+                       attribs = [ ]
+                       for (attrib, value) in self.skinAttributes:
+                               if attrib == "EntryForegroundColor":
+                                       self.foreColor = parseColor(value).argb()
+                               elif attrib == "EntryBorderColor":
+                                       self.borderColor = parseColor(value).argb()
+                               elif attrib == "EntryBackgroundColor":
+                                       self.backColor = parseColor(value).argb()
+                               elif attrib == "EntryBackgroundColorSelected":
+                                       self.backColorSelected = parseColor(value).argb()
+                               else:
+                                       attribs.append((attrib,value))
+                       self.skinAttributes = attribs
                return GUIComponent.applySkin(self, desktop)
 
        def isSelectable(self, service, sname, event_list):